statichttp: use 'repo.vfs' as the main attribute
We are about to deprecate the repo.opener attribute, we prepare the static http
code to be ready for this change.
--- a/mercurial/statichttprepo.py Thu Mar 02 03:23:18 2017 +0100
+++ b/mercurial/statichttprepo.py Thu Mar 02 03:24:58 2017 +0100
@@ -121,9 +121,9 @@
u = util.url(path.rstrip('/') + "/.hg")
self.path, authinfo = u.authinfo()
- opener = build_opener(ui, authinfo)
- self.opener = opener(self.path)
- self.vfs = self.opener
+ vfsclass = build_opener(ui, authinfo)
+ self.vfs = vfsclass(self.path)
+ self.opener = self.vfs
self._phasedefaults = []
self.names = namespaces.namespaces()
@@ -148,7 +148,7 @@
raise error.RepoError(msg)
# setup store
- self.store = store.store(requirements, self.path, opener)
+ self.store = store.store(requirements, self.path, vfsclass)
self.spath = self.store.path
self.svfs = self.store.opener
self.sjoin = self.store.join