Skip to content

Commit 689967d

Browse files
committed
Don't try loading user plugins if the directory is not set in configuration
1 parent ab630c0 commit 689967d

1 file changed

Lines changed: 6 additions & 4 deletions

File tree

gremlin/plugin_manager.py

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -49,11 +49,13 @@ def __init__(self):
4949
self._parameter_requirements = {}
5050

5151
self._discover_plugins(Path(util.resource_path("action_plugins")), True)
52-
path = Path(config.Configuration().value(
52+
user_plugin_dir = config.Configuration().value(
5353
"global", "general", "plugin_directory"
54-
))
55-
if path.is_dir():
56-
self._discover_plugins(path, False)
54+
)
55+
if user_plugin_dir:
56+
path = Path(user_plugin_dir)
57+
if path.is_dir():
58+
self._discover_plugins(path, False)
5759

5860
self._create_type_action_map()
5961
self._create_action_name_map()

0 commit comments

Comments
 (0)