Mercurial > hg
changeset 26324:4a8e21578e14
addremove: remove a mutable default argument
Mutable default arguments are know to the state of California to cause bugs.
author | Pierre-Yves David <pierre-yves.david@fb.com> |
---|---|
date | Thu, 24 Sep 2015 01:58:33 -0700 |
parents | ed884807dc48 |
children | cce8ebd31407 |
files | mercurial/cmdutil.py |
diffstat | 1 files changed, 3 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/cmdutil.py Thu Sep 24 00:56:30 2015 -0700 +++ b/mercurial/cmdutil.py Thu Sep 24 01:58:33 2015 -0700 @@ -2763,7 +2763,9 @@ return "\n".join(edittext) -def commitstatus(repo, node, branch, bheads=None, opts={}): +def commitstatus(repo, node, branch, bheads=None, opts=None): + if opts is None: + opts = {} ctx = repo[node] parents = ctx.parents()