D3876: rebase: check whether the rebasestate exists or not a bit early
pulkit (Pulkit Goyal)
phabricator at mercurial-scm.org
Mon Jul 2 12:43:20 UTC 2018
This revision was automatically updated to reflect the committed changes.
Closed by commit rHGcf24f678adda: rebase: check whether the rebasestate exists or not a bit early (authored by pulkit, committed by ).
REPOSITORY
rHG Mercurial
CHANGES SINCE LAST UPDATE
https://phab.mercurial-scm.org/D3876?vs=9398&id=9407
REVISION DETAIL
https://phab.mercurial-scm.org/D3876
AFFECTED FILES
hgext/rebase.py
CHANGE DETAILS
diff --git a/hgext/rebase.py b/hgext/rebase.py
--- a/hgext/rebase.py
+++ b/hgext/rebase.py
@@ -227,6 +227,9 @@
def restorestatus(self):
"""Restore a previously stored status"""
+ if not self.stateobj.exists():
+ cmdutil.wrongtooltocontinue(self.repo, _('rebase'))
+
data = self._read()
self.repo.ui.debug('rebase status resumed\n')
@@ -250,9 +253,7 @@
state = {}
destmap = {}
- if not self.stateobj.exists():
- cmdutil.wrongtooltocontinue(repo, _('rebase'))
- else:
+ if True:
f = repo.vfs("rebasestate")
for i, l in enumerate(f.read().splitlines()):
if i == 0:
To: pulkit, #hg-reviewers
Cc: mercurial-devel
More information about the Mercurial-devel
mailing list