Mercurial > public > mercurial-scm > hg-stable
diff mercurial/cmdutil.py @ 35168:3da4bd50103d
py3: fix handling of keyword arguments in revert
Differential Revision: https://phab.mercurial-scm.org/D1554
author | Pulkit Goyal <7895pulkit@gmail.com> |
---|---|
date | Wed, 29 Nov 2017 07:57:17 +0530 |
parents | 7a58608281dd |
children | ee64e677c3cf |
line wrap: on
line diff
--- a/mercurial/cmdutil.py Tue Nov 28 11:00:54 2017 -0500 +++ b/mercurial/cmdutil.py Wed Nov 29 07:57:17 2017 +0530 @@ -3445,6 +3445,7 @@ return repo.status(match=scmutil.match(repo[None], pats, opts)) def revert(ui, repo, ctx, parents, *pats, **opts): + opts = pycompat.byteskwargs(opts) parent, p2 = parents node = ctx.node() @@ -3722,7 +3723,8 @@ # Revert the subrepos on the revert list for sub in targetsubs: try: - wctx.sub(sub).revert(ctx.substate[sub], *pats, **opts) + wctx.sub(sub).revert(ctx.substate[sub], *pats, + **pycompat.strkwargs(opts)) except KeyError: raise error.Abort("subrepository '%s' does not exist in %s!" % (sub, short(ctx.node())))