# HG changeset patch # User Gregory Szorc # Date 1489380737 25200 # Node ID d2878bec55bdc12623995f93bf05a5423d99ab5a # Parent 7dafa8d0e00670f33e811284575d0061b8fccd43 hgweb: don't use mutable default argument value diff -r 7dafa8d0e006 -r d2878bec55bd mercurial/hgweb/webutil.py --- a/mercurial/hgweb/webutil.py Mon Dec 26 16:55:47 2016 -0700 +++ b/mercurial/hgweb/webutil.py Sun Mar 12 21:52:17 2017 -0700 @@ -142,8 +142,8 @@ return hex(self._changelog.node(self._revlog.linkrev(rev))) class _siblings(object): - def __init__(self, siblings=[], hiderev=None): - self.siblings = [s for s in siblings if s.node() != nullid] + def __init__(self, siblings=None, hiderev=None): + self.siblings = [s for s in siblings or [] if s.node() != nullid] if len(self.siblings) == 1 and self.siblings[0].rev() == hiderev: self.siblings = []