From: Toshi MARUYAMA Date: Sat, 22 Nov 2014 13:45:35 +0000 (+0000) Subject: 2.6-stable: fix syntax error on Ruby 1.8.7 (#18280) X-Git-Tag: 2.6.1~35 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=6ddae89affdab9f8433d167c000a1d90891ea366;p=redmine.git 2.6-stable: fix syntax error on Ruby 1.8.7 (#18280) git-svn-id: http://svn.redmine.org/redmine/branches/2.6-stable@13640 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- diff --git a/app/models/issue_status.rb b/app/models/issue_status.rb index 3b1dd08da..1e491e90b 100644 --- a/app/models/issue_status.rb +++ b/app/models/issue_status.rb @@ -104,7 +104,8 @@ class IssueStatus < ActiveRecord::Base " JOIN #{JournalDetail.table_name} d ON d.journal_id = j.id" + " WHERE j.journalized_type = 'Issue' AND j.journalized_id = #{Issue.table_name}.id" + " AND d.property = 'attr' AND d.prop_key = 'status_id' AND d.value = :status_id" - Issue.where(:status_id => id, :closed_on => nil).update_all(["closed_on = (#{subselect})", :status_id => id.to_s]) + Issue.where(:status_id => id, :closed_on => nil). + update_all(["closed_on = (#{subselect})", {:status_id => id.to_s}]) # Then we update issues that don't have a journal which means the # current status was set on creation