Skip to content
This repository has been archived by the owner on Aug 6, 2019. It is now read-only.

Fix for Redmine 3.3.2 #16

Open
dani-sanchez-dorado opened this issue Jan 18, 2017 · 1 comment
Open

Fix for Redmine 3.3.2 #16

dani-sanchez-dorado opened this issue Jan 18, 2017 · 1 comment

Comments

@dani-sanchez-dorado
Copy link

Hello,
I have been using Redmine Rubycas for years in my Redmine 2.3.3 installation without any problem. Now, I'm migrating to Redmine 3.3.2 and I have found that this plug-in doesn't work. I get this error:

You should not use the match method in your router without specifying an HTTP method

My Redmine configuration is this:

Environment:
Redmine version 3.3.2.stable
Ruby version 2.1.2-p95 (2014-05-08) [x86_64-linux-gnu]
Rails version 4.2.7.1
Environment production
Database adapter Mysql2
SCM:
Subversion 1.8.10
Cvs 1.12.12
Git 2.6.6
Filesystem
Redmine plugins:
clipboard_image_paste 1.8
redmine_checklists 3.1.5
redmine_ckeditor 1.1.4
redmine_edit_custom_fields 0.0.4
redmine_rubycas 0.0.6

After googling a while, I have found this article about my problem:
http://stackoverflow.com/questions/19798466/rails-4-you-should-not-use-the-match-method-in-your-router-without-specifying

I apply this solution and works perfectly. Simple change the file

plugins/redmine_rubycas/config/routes.rb

The original code was:

match 'login_without_cas', :to => 'account#login_without_cas', :as => 'signin_without_cas'
match 'logout_without_cas', :to => 'account#logout_without_cas', :as => 'signout_without_cas'

I fix it with this changes:

match 'login_without_cas', :to => 'account#login_without_cas', :via => [:get], :as => 'signin_without_cas'
match 'logout_without_cas', :to => 'account#logout_without_cas', :via => [:get], :as => 'signout_without_cas'

I think it would be interesting for all users ;),

Thanks !!

@dani-sanchez-dorado
Copy link
Author

It would be possible to add to your code?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant