diff options
author | Matthew Landauer <matthew@openaustralia.org> | 2013-03-22 14:50:01 +1100 |
---|---|---|
committer | Matthew Landauer <matthew@openaustralia.org> | 2013-03-22 14:50:01 +1100 |
commit | 661ad52ef88de7afcbd7820d8283057764f4d1ac (patch) | |
tree | dcaebe1fd1020c10c74d55261e6312e49a2a2104 /config/routes.rb | |
parent | adac483b0f8133c8d9623dba24b6c52f1cc0f8a9 (diff) |
Only allow posts for reporting request. Don't try redirection when not logged in
Diffstat (limited to 'config/routes.rb')
-rw-r--r-- | config/routes.rb | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/config/routes.rb b/config/routes.rb index 60e33b3cf..4869990e3 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -59,14 +59,8 @@ Alaveteli::Application.routes.draw do match '/upload/request/:url_title' => 'request#upload_response', :as => :upload_response match '/request/:url_title/download' => 'request#download_entire_request', :as => :download_entire_request - # It would be nice to add :conditions => { :method => :post } to this next one, - # because it ought not really to be available as a GET request since it changes - # the server state. Unfortunately this doesn’t play well with the PostRedirect - # mechanism, which assumes all post-login actions are available via GET, so we - # refrain. - match '/request/:url_title/report' => 'request#report_request', :as => :report + match '/request/:url_title/report' => 'request#report_request', :as => :report, :via => :post match '/request/:url_title/report/new' => 'request#new_report_request', :as => :new_report_request - #### #### User controller |