Mercurial > hg-stable
changeset 17846:f42cf30873dc stable
scmutil: add mustaudit delegation to filtervfs (issue3673)
author | Bryan O'Sullivan <bryano@fb.com> |
---|---|
date | Mon, 22 Oct 2012 12:00:21 -0700 |
parents | 408ded42c5ec |
children | 1e4eb1faba6e 1f34b57ca319 |
files | mercurial/scmutil.py |
diffstat | 1 files changed, 6 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/scmutil.py Mon Oct 22 11:59:11 2012 -0700 +++ b/mercurial/scmutil.py Mon Oct 22 12:00:21 2012 -0700 @@ -360,21 +360,21 @@ mustaudit = property(_getmustaudit, _setmustaudit) -class filtervfs(abstractvfs): +class filtervfs(abstractvfs, auditvfs): '''Wrapper vfs for filtering filenames with a function.''' - def __init__(self, opener, filter): + def __init__(self, vfs, filter): + auditvfs.__init__(self, vfs) self._filter = filter - self._orig = opener def __call__(self, path, *args, **kwargs): - return self._orig(self._filter(path), *args, **kwargs) + return self.vfs(self._filter(path), *args, **kwargs) def join(self, path): if path: - return self._orig.join(self._filter(path)) + return self.vfs.join(self._filter(path)) else: - return self._orig.join(path) + return self.vfs.join(path) filteropener = filtervfs