From ebe712312cf5625381e8f875b2cc6a91ee8838d6 Mon Sep 17 00:00:00 2001 From: Matthias Date: Sat, 20 Nov 2021 03:31:58 +0100 Subject: [PATCH] refactor --- InvenTree/InvenTree/settings.py | 2 +- InvenTree/plugin/plugins.py | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/InvenTree/InvenTree/settings.py b/InvenTree/InvenTree/settings.py index 732b4a5131..6027e60bb2 100644 --- a/InvenTree/InvenTree/settings.py +++ b/InvenTree/InvenTree/settings.py @@ -889,7 +889,7 @@ INTEGRATION_PLUGIN_GLOBALSETTING = {} INTEGRATION_APPS_LOADING = True # Marks if apps were reloaded yet INTEGRATION_PLUGINS_RELOADING = False INTEGRATION_APPS_PATHS = [] # Holds all added plugin_paths -INTEGRATION_STARTUP_ERRORS = {} # Holds discovering errors +INTEGRATION_ERRORS = {} # Holds discovering errors # Test settings PLUGIN_TESTING = get_setting('PLUGIN_TESTING', TESTING) # used to force enable everything plugin diff --git a/InvenTree/plugin/plugins.py b/InvenTree/plugin/plugins.py index 1732dd641c..7271ab8752 100644 --- a/InvenTree/plugin/plugins.py +++ b/InvenTree/plugin/plugins.py @@ -46,11 +46,11 @@ def get_modules(pkg, recursive: bool = False): # TODO log # make sure the registry is set up - if 'discovery' not in settings.INTEGRATION_STARTUP_ERRORS: - settings.INTEGRATION_STARTUP_ERRORS['discovery'] = [] + if 'discovery' not in settings.INTEGRATION_ERRORS: + settings.INTEGRATION_ERRORS['discovery'] = [] # add error to stack - settings.INTEGRATION_STARTUP_ERRORS['discovery'].append({name: str(error)}) + settings.INTEGRATION_ERRORS['discovery'].append({name: str(error)}) return [v for k, v in context.items()]