From 3606bd8fe45d7bf43f8009c173d856d7e8ba52d2 Mon Sep 17 00:00:00 2001 From: Matthias Date: Wed, 16 Mar 2022 17:03:04 +0100 Subject: [PATCH] add try to settings test --- InvenTree/plugin/apps.py | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/InvenTree/plugin/apps.py b/InvenTree/plugin/apps.py index 93f1b89b6e..ff03fdd04e 100644 --- a/InvenTree/plugin/apps.py +++ b/InvenTree/plugin/apps.py @@ -30,11 +30,13 @@ class PluginAppConfig(AppConfig): if not registry.is_loading: # this is the first startup - from common.models import InvenTreeSetting - - if InvenTreeSetting.get_setting('PLUGIN_ON_STARTUP'): - # make sure all plugins are installed - registry.install_plugin_file() + try: + from common.models import InvenTreeSetting + if InvenTreeSetting.get_setting('PLUGIN_ON_STARTUP'): + # make sure all plugins are installed + registry.install_plugin_file() + except: + pass # get plugins and init them registry.collect_plugins()