mirror of
https://github.com/aljazceru/python-teos.git
synced 2025-12-17 14:14:22 +01:00
cli - fixes cli without params
Cli was crashing if no param was provided
This commit is contained in:
@@ -484,7 +484,7 @@ if __name__ == "__main__":
|
|||||||
if opt in ["-h", "--help"]:
|
if opt in ["-h", "--help"]:
|
||||||
sys.exit(show_usage())
|
sys.exit(show_usage())
|
||||||
|
|
||||||
command = args.pop(0)
|
command = args.pop(0) if args else None
|
||||||
if command in commands:
|
if command in commands:
|
||||||
main(command, args, command_line_conf)
|
main(command, args, command_line_conf)
|
||||||
elif not command:
|
elif not command:
|
||||||
|
|||||||
Reference in New Issue
Block a user