Bläddra i källkod

[enh] plugin id

Adam Tauber 10 år sedan
förälder
incheckning
9cb66be29c
1 ändrade filer med 1 tillägg och 0 borttagningar
  1. 1
    0
      searx/plugins/__init__.py

+ 1
- 0
searx/plugins/__init__.py Visa fil

@@ -29,6 +29,7 @@ class PluginStore():
29 29
                 if not hasattr(plugin, plugin_attr):
30 30
                     logger.critical('missing attribute "{0}", cannot load plugin: {1}'.format(plugin_attr, plugin))
31 31
                     exit(3)
32
+            plugin.id = plugin.name.replace(' ', '_')
32 33
             self.plugins.append(plugin)
33 34
 
34 35
     def call(self, plugin_type, request, *args, **kwargs):