diff --git a/mercurial/cmdutil.py b/mercurial/cmdutil.py --- a/mercurial/cmdutil.py +++ b/mercurial/cmdutil.py @@ -38,7 +38,6 @@ logcmdutil, match as matchmod, merge as mergemod, - mergestate as mergestatemod, mergeutil, obsolete, patch, @@ -891,7 +890,7 @@ def readmorestatus(repo): """Returns a morestatus object if the repo has unfinished state.""" statetuple = statemod.getrepostate(repo) - mergestate = mergestatemod.mergestate.read(repo) + mergestate = repo[None].mergestate() activemerge = mergestate.active() if not statetuple and not activemerge: return None @@ -3141,7 +3140,7 @@ if subs: subrepoutil.writestate(repo, newsubstate) - ms = mergestatemod.mergestate.read(repo) + ms = repo[None].mergestate() mergeutil.checkunresolved(ms) filestoamend = {f for f in wctx.files() if matcher(f)}