Commit 51ed5402 authored by Paul McCarthy's avatar Paul McCarthy 🚵
Browse files

BF: don't call confirmDestination if no plugins selected

parent 4d15eee1
......@@ -229,6 +229,7 @@ def confirmDestination(plugins : List[Plugin]):
to refer to the destination(s) selected by the user.
"""
assert len(plugins) > 0
assert all([p.destination is not None for p in plugins])
instr = 'type the path into which you would like all plugins to be ' \
......
......@@ -253,7 +253,9 @@ def selectPlugins(args : argparse.Namespace,
# the destination directory for each
# plugin (unless --force is active,
# in which case defaults are used)
if args.destination is None and (not args.force):
if all((len(plugins) > 0,
args.destination is None,
not args.force)):
ui.confirmDestination(plugins)
return plugins
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment