diff options
author | Robert Speicher <rspeicher@gmail.com> | 2015-04-07 06:02:06 +0300 |
---|---|---|
committer | Robert Speicher <rspeicher@gmail.com> | 2015-04-07 06:08:28 +0300 |
commit | 167a6b9eefd2076d08b4f1504f8b5ff3fb281026 (patch) | |
tree | 59e6e75dc5c10d92da99b25a74d083e50862b2a6 /app/controllers/projects/refs_controller.rb | |
parent | 0d0042d27481d31027a10edb2ba3a184bff5075a (diff) |
Render a 404 when RefsController#logs_tree gets an HTML request
Fixes #2152
Diffstat (limited to 'app/controllers/projects/refs_controller.rb')
-rw-r--r-- | app/controllers/projects/refs_controller.rb | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/app/controllers/projects/refs_controller.rb b/app/controllers/projects/refs_controller.rb index 67acf45ab7f..ec3b2b8d75a 100644 --- a/app/controllers/projects/refs_controller.rb +++ b/app/controllers/projects/refs_controller.rb @@ -55,5 +55,10 @@ class Projects::RefsController < Projects::ApplicationController commit: last_commit } end + + respond_to do |format| + format.html { render_404 } + format.js + end end end |