mirror of
https://github.com/openSUSE/osc.git
synced 2024-11-14 08:16:15 +01:00
cmdln: Fix hide() decorator to take an optional argument with a boolean value
To restore compatibility with the install plugin.
This commit is contained in:
parent
c1f0cfa1b7
commit
cb52884f86
@ -61,7 +61,7 @@ def name(name):
|
||||
return decorate
|
||||
|
||||
|
||||
def hide():
|
||||
def hide(value=True):
|
||||
"""
|
||||
For obsolete calls, hide them in help listings.
|
||||
|
||||
@ -72,7 +72,7 @@ def hide():
|
||||
#...implement 'shell' command
|
||||
"""
|
||||
def decorate(f):
|
||||
f.hidden = True
|
||||
f.hidden = bool(value)
|
||||
return f
|
||||
return decorate
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user