summaryrefslogtreecommitdiffstats
path: root/app/models/repository
diff options
context:
space:
mode:
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>2015-01-18 16:40:34 +0000
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>2015-01-18 16:40:34 +0000
commitad9fd2b66b2a704a680c597eb3ce26f60b0095b7 (patch)
tree9e8f545ef8dd0828e1157a9452f86a0f06961ae2 /app/models/repository
parent2cc3ba063fa06f7326ba5dd0303e1b17fb443564 (diff)
downloadredmine-ad9fd2b66b2a704a680c597eb3ce26f60b0095b7.tar.gz
redmine-ad9fd2b66b2a704a680c597eb3ce26f60b0095b7.zip
use "where" instead of find_by_ at Repository::Cvs class
git-svn-id: http://svn.redmine.org/redmine/trunk@13904 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/models/repository')
-rw-r--r--app/models/repository/cvs.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/app/models/repository/cvs.rb b/app/models/repository/cvs.rb
index e61ede50d..000e3e004 100644
--- a/app/models/repository/cvs.rb
+++ b/app/models/repository/cvs.rb
@@ -57,9 +57,9 @@ class Repository::Cvs < Repository
if entries
entries.each() do |entry|
if ( ! entry.lastrev.nil? ) && ( ! entry.lastrev.revision.nil? )
- change = filechanges.find_by_revision_and_path(
- entry.lastrev.revision,
- scm.with_leading_slash(entry.path) )
+ change = filechanges.where(
+ :revision => entry.lastrev.revision,
+ :path => scm.with_leading_slash(entry.path)).first
if change
entry.lastrev.identifier = change.changeset.revision
entry.lastrev.revision = change.changeset.revision