summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>2011-03-19 15:50:08 +0000
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>2011-03-19 15:50:08 +0000
commit3ea7b9a7688b5cfac6005f1b61d459e26995b20a (patch)
treee6bf706782ad11e94b84de4094f8822c44155ac2 /lib
parent08429506c5732dc2c097df05128353da3b4b7f07 (diff)
downloadredmine-3ea7b9a7688b5cfac6005f1b61d459e26995b20a.tar.gz
redmine-3ea7b9a7688b5cfac6005f1b61d459e26995b20a.zip
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
Diffstat (limited to 'lib')
-rw-r--r--lib/redmine/scm/adapters/git_adapter.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/redmine/scm/adapters/git_adapter.rb b/lib/redmine/scm/adapters/git_adapter.rb
index 6d012a7ec..88acc2ed5 100644
--- a/lib/redmine/scm/adapters/git_adapter.rb
+++ b/lib/redmine/scm/adapters/git_adapter.rb
@@ -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