scm: git: insert revisions to database with reverse commit order (#7821, #5357).

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5073 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Toshi MARUYAMA 2011-03-10 04:30:47 +00:00
parent b235e36946
commit 6dc57e752d
1 changed files with 1 additions and 1 deletions

View File

@ -77,7 +77,7 @@ class Repository::Git < Repository
c = changesets.find(:first, :order => 'committed_on DESC')
since = (c ? c.committed_on - 7.days : nil)
revisions = scm.revisions('', nil, nil, :all => true, :since => since)
revisions = scm.revisions('', nil, nil, {:all => true, :since => since, :reverse => true})
return if revisions.nil? || revisions.empty?
recent_changesets = changesets.find(:all, :conditions => ['committed_on >= ?', since])