diff options
author | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2019-05-30 06:57:09 +0000 |
---|---|---|
committer | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2019-05-30 06:57:09 +0000 |
commit | e0738ac6e9b94b247a17375432031c98311a5bb9 (patch) | |
tree | 1590ccf0ccf2932a92e0022e7d6c13b2cc05baf5 /app/controllers/repositories_controller.rb | |
parent | 820cbe618e99d16f1842c2c9d93aad89121bd1ba (diff) | |
download | redmine-e0738ac6e9b94b247a17375432031c98311a5bb9.tar.gz redmine-e0738ac6e9b94b247a17375432031c98311a5bb9.zip |
scm: early return in diff if diff is nil as same as show, changes, and etc. (#31141, #30850)
Contributed by Mizuki ISHIKAWA.
git-svn-id: http://svn.redmine.org/redmine/trunk@18206 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/controllers/repositories_controller.rb')
-rw-r--r-- | app/controllers/repositories_controller.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/controllers/repositories_controller.rb b/app/controllers/repositories_controller.rb index a35e2956c..9f4745464 100644 --- a/app/controllers/repositories_controller.rb +++ b/app/controllers/repositories_controller.rb @@ -257,7 +257,7 @@ class RepositoriesController < ApplicationController Digest::MD5.hexdigest("#{@path}-#{@rev}-#{@rev_to}-#{@diff_type}-#{current_language}") unless read_fragment(@cache_key) @diff = @repository.diff(@path, @rev, @rev_to) - show_error_not_found unless @diff + (show_error_not_found; return) unless @diff end @changeset = @repository.find_changeset_by_name(@rev) |