diff options
author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2014-12-28 22:15:09 +0200 |
---|---|---|
committer | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2014-12-28 22:15:09 +0200 |
commit | 3a678f758d75413e0377816e5de01d7fcd10f0e9 (patch) | |
tree | 7d636cae432edde0c79a63fff7f41120da9eb13b /config | |
parent | 25a42a56cf4da95e8725b988f2b940d8b293a952 (diff) | |
parent | 6d4076fdc674cd5f9002e908e082d6c1c9dd1b90 (diff) | |
download | gitlab-ce-3a678f758d75413e0377816e5de01d7fcd10f0e9.tar.gz |
Merge pull request #7989 from cirosantilli/match-compare-to-get
Disallow POST to compare as it does not create objects
Diffstat (limited to 'config')
-rw-r--r-- | config/routes.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/config/routes.rb b/config/routes.rb index 1d571e21b88..9b99f0643a7 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -218,7 +218,8 @@ Gitlab::Application.routes.draw do end end - match "/compare/:from...:to" => "compare#show", as: "compare", via: [:get, :post], constraints: {from: /.+/, to: /.+/} + get '/compare/:from...:to' => 'compare#show', :as => 'compare', + :constraints => {from: /.+/, to: /.+/} resources :snippets, constraints: {id: /\d+/} do member do |