script: Encapsuled Connection into with

master
Felix Stupp 4 years ago
parent 3b91105aea
commit 45e97f8523
Signed by: zocker
GPG Key ID: 93E1BD26F6B02FB7

@ -69,7 +69,7 @@ def main():
host = urlM['host']
# Call api
# TODO Support port
server = Connection(proto=proto, host=host)
with Connection(proto=proto, host=host) as server:
server.login(args.user, passwd)
args.func(server, args)

Loading…
Cancel
Save