mercurial/localrepo.py
changeset 14102 7f45b1911893
parent 14076 924c82157d46
child 14144 3c3c53d8343a
child 14150 3a3584967a93
--- a/mercurial/localrepo.py	Sat Apr 30 12:02:09 2011 -0500
+++ b/mercurial/localrepo.py	Sun May 01 11:12:36 2011 +0200
@@ -1918,10 +1918,18 @@
         return self.pull(remote, heads)
 
     def pushkey(self, namespace, key, old, new):
-        return pushkey.push(self, namespace, key, old, new)
+        self.hook('prepushkey', throw=True, namespace=namespace, key=key,
+                  old=old, new=new)
+        ret = pushkey.push(self, namespace, key, old, new)
+        self.hook('pushkey', namespace=namespace, key=key, old=old, new=new,
+                  ret=ret)
+        return ret
 
     def listkeys(self, namespace):
-        return pushkey.list(self, namespace)
+        self.hook('prelistkeys', throw=True, namespace=namespace)
+        values = pushkey.list(self, namespace)
+        self.hook('listkeys', namespace=namespace, values=values)
+        return values
 
     def debugwireargs(self, one, two, three=None, four=None, five=None):
         '''used to test argument passing over the wire'''