mirror of
https://github.com/facebook/sapling.git
synced 2024-10-08 07:49:11 +03:00
zeroconf: blindly forward extra argument to the core config method
The new default value handling is simpler if we let the original function handle everything.
This commit is contained in:
parent
a418240d11
commit
d997c3083a
@ -167,12 +167,12 @@ def getzcpaths():
|
||||
value.properties.get("path", "/"))
|
||||
yield "zc-" + name, url
|
||||
|
||||
def config(orig, self, section, key, default=None, untrusted=False):
|
||||
def config(orig, self, section, key, *args, **kwargs):
|
||||
if section == "paths" and key.startswith("zc-"):
|
||||
for name, path in getzcpaths():
|
||||
if name == key:
|
||||
return path
|
||||
return orig(self, section, key, default, untrusted)
|
||||
return orig(self, section, key, *args, **kwargs)
|
||||
|
||||
def configitems(orig, self, section, *args, **kwargs):
|
||||
repos = orig(self, section, *args, **kwargs)
|
||||
|
Loading…
Reference in New Issue
Block a user