From d1c2a399ebb5f1a42d20f620d9e4a62c51d1365b Mon Sep 17 00:00:00 2001 From: Matthias Date: Mon, 4 Oct 2021 12:19:43 +0200 Subject: [PATCH] Default value for SLug is None --- InvenTree/plugins/integration.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/InvenTree/plugins/integration.py b/InvenTree/plugins/integration.py index f8641af6cd..60716773e5 100644 --- a/InvenTree/plugins/integration.py +++ b/InvenTree/plugins/integration.py @@ -237,6 +237,7 @@ class IntegrationPluginBase(MixinBase, plugin.InvenTreePlugin): """ The IntegrationPluginBase class is used to integrate with 3rd party software """ + PLUGIN_SLUG = None def __init__(self): super().__init__() @@ -249,7 +250,9 @@ class IntegrationPluginBase(MixinBase, plugin.InvenTreePlugin): @property def slug(self): """slug for the plugin""" - name = getattr(self, 'PLUGIN_SLUG', self.plugin_name()) + name = getattr(self, 'PLUGIN_SLUG', None) + if not name: + name = self.plugin_name() return slugify(name) def mixin(self, key):