From 9bd34e13c7b21be3cde7013514c3f84c749c0ff7 Mon Sep 17 00:00:00 2001 From: Joel Collins Date: Wed, 15 Apr 2020 14:26:40 +0100 Subject: [PATCH] Handle missing Flask extension in current_labthing --- labthings/server/find.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/labthings/server/find.py b/labthings/server/find.py index c59a771e..195b49a3 100644 --- a/labthings/server/find.py +++ b/labthings/server/find.py @@ -19,7 +19,7 @@ def current_labthing(app=None): logging.debug("Active app extensions:") logging.debug(app.extensions) logging.debug("Active labthing:") - logging.debug(app.extensions[EXTENSION_NAME]) + logging.debug(app.extensions.get(EXTENSION_NAME)) return app.extensions.get(EXTENSION_NAME, None)