Submitter | Pierre-Yves David |
---|---|
Date | Nov. 13, 2014, 5:04 p.m. |
Message ID | <d6bae78a0cd5293b9f66.1415898299@marginatus.alto.octopoid.net> |
Download | mbox | patch |
Permalink | /patch/6711/ |
State | Accepted |
Commit | 59513ec767481e34f4effb05d4b883e34051d27b |
Headers | show |
Comments
Patch
diff --git a/mercurial/transaction.py b/mercurial/transaction.py --- a/mercurial/transaction.py +++ b/mercurial/transaction.py @@ -327,16 +327,17 @@ class transaction(object): self._postclosecallback[category] = callback @active def close(self): '''commit the transaction''' - if self.count == 1 and self.onclose is not None: + if self.count == 1: self._generatefiles() categories = sorted(self._finalizecallback) for cat in categories: self._finalizecallback[cat](self) - self.onclose() + if self.onclose is not None: + self.onclose() self.count -= 1 if self.count != 0: return self.file.close()