mercurial/obsolete.py
changeset 40029 e2697acd9381
parent 39922 6335c0de80fa
child 40042 208303a8172c
--- a/mercurial/obsolete.py	Tue Oct 02 12:43:54 2018 -0700
+++ b/mercurial/obsolete.py	Wed Oct 03 10:27:44 2018 -0700
@@ -997,13 +997,13 @@
             if not isinstance(predecessors, tuple):
                 # preserve compat with old API until all caller are migrated
                 predecessors = (predecessors,)
-            if 1 < len(predecessors) and len(rel[1]) != 1:
+            if len(predecessors) > 1 and len(rel[1]) != 1:
                 msg = 'Fold markers can only have 1 successors, not %d'
                 raise error.ProgrammingError(msg % len(rel[1]))
             for prec in predecessors:
                 sucs = rel[1]
                 localmetadata = metadata.copy()
-                if 2 < len(rel):
+                if len(rel) > 2:
                     localmetadata.update(rel[2])
 
                 if not prec.mutable():