diff options
author | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2015-10-29 13:47:28 +0000 |
---|---|---|
committer | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2015-10-29 13:47:28 +0000 |
commit | 1919f7233f2d43527c3038553268805c36896123 (patch) | |
tree | d7afa940e281a30ffac52cdf6626159425ce6166 /app | |
parent | 6d8635aed9fcdcb64ac7636e00ea956bebf2074f (diff) | |
download | redmine-1919f7233f2d43527c3038553268805c36896123.tar.gz redmine-1919f7233f2d43527c3038553268805c36896123.zip |
find_referenced_issue_by_id fails with RangeError for large numbers (#21071).
git-svn-id: http://svn.redmine.org/redmine/trunk@14758 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app')
-rw-r--r-- | app/models/changeset.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/changeset.rb b/app/models/changeset.rb index 13213f3ab..ae42d414e 100644 --- a/app/models/changeset.rb +++ b/app/models/changeset.rb @@ -200,7 +200,7 @@ class Changeset < ActiveRecord::Base # Finds an issue that can be referenced by the commit message def find_referenced_issue_by_id(id) return nil if id.blank? - issue = Issue.includes(:project).where(:id => id.to_i).first + issue = Issue.find_by_id(id.to_i) if Setting.commit_cross_project_ref? # all issues can be referenced/fixed elsif issue |