diff options
Diffstat (limited to 'opendc')
| -rw-r--r-- | opendc/util/rest.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/opendc/util/rest.py b/opendc/util/rest.py index 65747762..ad53f084 100644 --- a/opendc/util/rest.py +++ b/opendc/util/rest.py @@ -13,11 +13,14 @@ with open(sys.argv[1]) as file: class Request(object): """WebSocket message to REST request mapping.""" - def __init__(self, message): + def __init__(self, message=None): """"Initialize a Request from a socket message.""" # Get the Request parameters from the message + if message is None: + return + try: self.message = message |
