electrum

Electrum Bitcoin wallet
git clone https://git.parazyd.org/electrum
Log | Files | Refs | Submodules

commit f9f6ea436519a3df65591a039a8e18ff358a711c
parent b96b5af10191511efc1ef8cd93d655c028503a03
Author: Janus <ysangkok@gmail.com>
Date:   Thu, 19 Jul 2018 12:43:53 +0200

commands: tolerate lack of argument to 'verbosity'

Diffstat:
Melectrum/commands.py | 4+++-
1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/electrum/commands.py b/electrum/commands.py @@ -829,7 +829,9 @@ def add_network_options(parser): def add_global_options(parser): group = parser.add_argument_group('global options') - group.add_argument("-v", "--verbosity", dest="verbosity", default='', help="Set verbosity filter") + # const is for when no argument is given to verbosity + # default is for when the flag is missing + group.add_argument("-v", "--verbosity", dest="verbosity", help="Set verbosity filter", default='', const='', nargs='?') group.add_argument("-D", "--dir", dest="electrum_path", help="electrum directory") group.add_argument("-P", "--portable", action="store_true", dest="portable", default=False, help="Use local 'electrum_data' directory") group.add_argument("-w", "--wallet", dest="wallet_path", help="wallet path")