mercurial/hg.py
changeset 5192 60acf1432ee0
parent 5187 c1dbc9ae8f2b
child 5248 5517aa5aafb0
--- a/mercurial/hg.py	Fri Aug 17 19:11:16 2007 +0200
+++ b/mercurial/hg.py	Fri Aug 17 17:33:27 2007 -0300
@@ -61,8 +61,10 @@
     """return a repository object for the specified path"""
     repo = _lookup(path).instance(ui, path, create)
     ui = getattr(repo, "ui", ui)
-    for hook in extensions.setuphooks:
-        hook(ui, repo)
+    for name, module in extensions.extensions():
+        hook = getattr(module, 'reposetup', None)
+        if hook:
+            hook(ui, repo)
     return repo
 
 def defaultdest(source):