1
0

cmdline: use 'wallet_path' argument to pass wallet_path

This commit is contained in:
ThomasV
2025-06-04 14:23:25 +02:00
parent 5efeaf13c5
commit 37914d5af0
3 changed files with 8 additions and 16 deletions

View File

@@ -367,10 +367,7 @@ class CommandsServer(AuthenticatedServer):
wallet_path = config_options.get('wallet_path')
if len(self.daemon._wallets) > 1 and wallet_path is None:
raise UserFacingException("error: wallet not specified")
if 'wallet_path' in cmd.options:
kwargs['wallet_path'] = wallet_path
else:
kwargs['wallet'] = wallet_path
kwargs['wallet_path'] = wallet_path
func = getattr(self.cmd_runner, cmd.name)
# execute requested command now. note: cmd can raise, the caller (self.handle) will wrap it.
result = await func(*args, **kwargs)