]> source.dussan.org Git - redmine.git/commitdiff
fixed bug 9537 fetch_changesets broken
authorJean-Philippe Lang <jp_lang@yahoo.fr>
Sun, 25 Mar 2007 22:33:40 +0000 (22:33 +0000)
committerJean-Philippe Lang <jp_lang@yahoo.fr>
Sun, 25 Mar 2007 22:33:40 +0000 (22:33 +0000)
git-svn-id: http://redmine.rubyforge.org/svn/trunk@382 e93f8b46-1217-0410-a6f0-8f06a7374b81

app/models/repository.rb

index 8f12ccc4ca80601fac388486ff8cc52ee6db5d0e..8b8de5c42f18b42a80000660a33b36ecbccc3abf 100644 (file)
@@ -45,14 +45,6 @@ class Repository < ActiveRecord::Base
     end 
   end
   
-  def changesets_for_path(path="")
-    path = "/#{path}%"
-    path = url.gsub(/^#{root_url}/, '') + path if root_url && root_url != url
-    path.squeeze!("/")
-    changesets.find(:all, :include => :changes,
-                          :conditions => ["#{Change.table_name}.path LIKE ?", path])
-  end
-  
   def fetch_changesets
     scm_info = scm.info
     if scm_info
@@ -80,7 +72,7 @@ class Repository < ActiveRecord::Base
                               :from_revision => change[:from_revision])
               end
             end
-          end
+          end unless revisions.nil?
           identifier_from = identifier_to + 1
         end
       end