Make .get() default explicit

This commit is contained in:
jesopo 2018-11-09 10:47:27 +00:00
parent 4bab1aea30
commit bc5f9351b1

View file

@ -31,7 +31,8 @@ class Module(ModuleManager.BaseModule):
@utils.hook("received.numeric.001")
def on_connect(self, event):
new_token = event["server"].connection_params.args.get("new-token")
new_token = event["server"].connection_params.args.get("new-token",
None)
if new_token:
event["server"].connection_params.args["resume"] = [
event["server"].nickname, new_token]