hgext/convert/hg.py
changeset 24306 6ddc86eedc3b
parent 23972 c408bf3b32f8
child 24395 216fa1ba9993
--- a/hgext/convert/hg.py	Fri Mar 13 14:20:13 2015 -0400
+++ b/hgext/convert/hg.py	Fri Mar 13 17:00:06 2015 -0400
@@ -87,7 +87,10 @@
         if not branch:
             branch = 'default'
         pbranches = [(b[0], b[1] and b[1] or 'default') for b in pbranches]
-        pbranch = pbranches and pbranches[0][1] or 'default'
+        if pbranches:
+            pbranch = pbranches[0][1]
+        else:
+            pbranch = 'default'
 
         branchpath = os.path.join(self.path, branch)
         if setbranch: