]> source.dussan.org Git - redmine.git/commitdiff
Reject empty Mercurial entries (#4098).
authorJean-Philippe Lang <jp_lang@yahoo.fr>
Wed, 11 Nov 2009 15:33:30 +0000 (15:33 +0000)
committerJean-Philippe Lang <jp_lang@yahoo.fr>
Wed, 11 Nov 2009 15:33:30 +0000 (15:33 +0000)
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@3029 e93f8b46-1217-0410-a6f0-8f06a7374b81

lib/redmine/scm/adapters/mercurial_adapter.rb

index ee7d7ea9d02064c0b8da365b2ac9fa4da380cbe1..79e2d13e2d1f01cbc6be1f4a0f355b8be4ab6475 100644 (file)
@@ -93,7 +93,7 @@ module Redmine
                                        :path => (path.nil? or path.empty? ? e.first : "#{with_trailling_slash(path)}#{e.first}"),
                                        :kind => (e.size > 1 ? 'dir' : 'file'),
                                        :lastrev => Revision.new
-                                     }) unless entries.detect{|entry| entry.name == e.first}
+                                     }) unless e.empty? || entries.detect{|entry| entry.name == e.first}
               end
             end
           end