From 8103203b0e2d6435096bcfd540d7d2c734ce0529 Mon Sep 17 00:00:00 2001 From: Bob Anderson Date: Tue, 9 Jan 2018 23:23:07 -0800 Subject: [PATCH] make client.py arm() option arg default to None for backward compatibility with HA --- concord232/client.py | 2 +- concord232_client | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/concord232/client.py b/concord232/client.py index 40086bb..4352b64 100755 --- a/concord232/client.py +++ b/concord232/client.py @@ -23,7 +23,7 @@ def list_partitions(self): except TypeError: return r.json()['partitions'] - def arm(self, level, option): + def arm(self, level, option = None): r = self._session.get( self._url + '/command', params={'cmd': 'arm', diff --git a/concord232_client b/concord232_client index 5d4737f..53b67de 100755 --- a/concord232_client +++ b/concord232_client @@ -39,7 +39,7 @@ def do_list_partitions(clnt, args): pprint.pprint(part) -def do_arm(clnt, level, option): +def do_arm(clnt, level, option = None): clnt.arm(level, option) def do_disarm(clnt, args): @@ -117,7 +117,7 @@ def main(): do_arm(clnt, level, option) else: cmd, level = args.command.split('-') - do_arm(clnt, level, None) + do_arm(clnt, level) elif args.command == 'disarm': do_disarm(clnt, args) elif args.command == 'keys':