Skip to content

Commit c070d52

Browse files
committed
refactor(CLI): use Safe argument instead of option
1 parent ef2ec2b commit c070d52

1 file changed

Lines changed: 4 additions & 6 deletions

File tree

ape_safe/_cli/modules.py

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -21,19 +21,17 @@ def modules():
2121

2222
@modules.command("list", cls=ConnectedProviderCommand)
2323
@network_option()
24-
@safe_cli_ctx()
25-
@safe_option
26-
def _list(cli_ctx, safe: "SafeAccount") -> None:
24+
@safe_argument
25+
def _list(safe: "SafeAccount"):
2726
"""List all modules enabled for SAFE"""
2827
for module in safe.modules:
2928
click.echo(repr(module))
3029

3130

3231
@modules.command(cls=ConnectedProviderCommand)
3332
@network_option()
34-
@safe_cli_ctx()
35-
@safe_option
36-
def guard(cli_ctx, safe: "SafeAccount") -> None:
33+
@safe_argument
34+
def guard(safe: "SafeAccount"):
3735
"""Show module guard (if enabled) for SAFE"""
3836
if guard := safe.modules.guard:
3937
click.echo(f"Guard: {guard}")

0 commit comments

Comments
 (0)