scm: git: default_branch() returns nil explicitly if branches are empty.
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5168 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
08429506c5
commit
3ea7b9a768
|
@ -102,7 +102,7 @@ module Redmine
|
|||
|
||||
def default_branch
|
||||
bras = self.branches
|
||||
return if bras.nil?
|
||||
return nil if bras.nil?
|
||||
bras.include?('master') ? 'master' : bras.first
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue