Mercurial > hg
changeset 24825:7f9655f37163 stable
pushkey: flush pending data before running a pre-pushkey hook (issue4607)
The pre-pushkey hook will likely validate the pushkey based on element
previously changed in the same transaction. We need to make theses data
available for the hook.
author | Pierre-Yves David <pierre-yves.david@fb.com> |
---|---|
date | Mon, 20 Apr 2015 17:16:05 +0200 |
parents | 0325c0da05df |
children | 9b02b678888e |
files | mercurial/localrepo.py |
diffstat | 1 files changed, 2 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/localrepo.py Mon Apr 20 17:15:50 2015 +0200 +++ b/mercurial/localrepo.py Mon Apr 20 17:16:05 2015 +0200 @@ -1905,6 +1905,8 @@ hookargs = {} if tr is not None: hookargs.update(tr.hookargs) + pending = lambda: tr.writepending() and self.root or "" + hookargs['pending'] = pending hookargs['namespace'] = namespace hookargs['key'] = key hookargs['old'] = old