diff mercurial/hg.py @ 660:2c83350784c3

Move commit hook after commit completes -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Move commit hook after commit completes manifest hash: bc65b570af67ee4748efaba2ff8a6cddf91b8a14 -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (GNU/Linux) iD8DBQFC0ZwSywK+sNU5EO8RAuAjAJsHGTXsOCnxq+xbq/Q0H+ayGnzaiQCfdWn6 or+IWK3sjYILYncTxMFZJdE= =mQb7 -----END PGP SIGNATURE-----
author Matt Mackall <mpm@selenic.com>
date Sun, 10 Jul 2005 14:07:14 -0800
parents 3662e3d6b690
children 31a9aa890016
line wrap: on
line diff
--- a/mercurial/hg.py	Sun Jul 10 14:06:30 2005 -0800
+++ b/mercurial/hg.py	Sun Jul 10 14:07:14 2005 -0800
@@ -802,15 +802,15 @@
         user = user or self.ui.username()
         n = self.changelog.add(mn, new, text, tr, p1, p2, user, date)
 
-        if not self.hook("commit", node=hex(n)):
-            return 1
-
         tr.close()
 
         self.dirstate.setparents(n)
         self.dirstate.update(new, "n")
         self.dirstate.forget(remove)
 
+        if not self.hook("commit", node=hex(n)):
+            return 1
+
     def changes(self, node1, node2, files=None):
         mf2, u = None, []