From 3fa8bd46511b44af1bae6fa64713c1f2990df3ab Mon Sep 17 00:00:00 2001 From: aronwk-aaron Date: Sun, 23 Oct 2022 17:39:20 -0500 Subject: [PATCH] fix handling new flag --- app/__init__.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/app/__init__.py b/app/__init__.py index e37d1ab..6b0a4af 100644 --- a/app/__init__.py +++ b/app/__init__.py @@ -264,10 +264,11 @@ def register_settings(app): 'USER_EMAIL_SENDER_EMAIL', app.config['USER_EMAIL_SENDER_EMAIL'] ) - app.config['ENABLE_CHAR_XML_UPLOAD'] = os.getenv( - 'ENABLE_CHAR_XML_UPLOAD', - app.config['ENABLE_CHAR_XML_UPLOAD'] - ) + if "ENABLE_CHAR_XML_UPLOAD" in app.config: + app.config['ENABLE_CHAR_XML_UPLOAD'] = os.getenv( + 'ENABLE_CHAR_XML_UPLOAD', + app.config['ENABLE_CHAR_XML_UPLOAD'] + ) def gm_level(gm_level):