mercurial/bundlerepo.py
changeset 47012 d55b71393907
parent 46907 ffd3e823a7e5
child 47072 4c041c71ec01
--- a/mercurial/bundlerepo.py	Mon Apr 19 20:38:52 2021 -0400
+++ b/mercurial/bundlerepo.py	Mon Mar 29 01:52:06 2021 +0200
@@ -19,7 +19,6 @@
 from .i18n import _
 from .node import (
     hex,
-    nullid,
     nullrev,
 )
 
@@ -447,7 +446,9 @@
         return encoding.getcwd()  # always outside the repo
 
     # Check if parents exist in localrepo before setting
-    def setparents(self, p1, p2=nullid):
+    def setparents(self, p1, p2=None):
+        if p2 is None:
+            p2 = self.nullid
         p1rev = self.changelog.rev(p1)
         p2rev = self.changelog.rev(p2)
         msg = _(b"setting parent to node %s that only exists in the bundle\n")