- for x in os.listdir(directory_category):
- path = directory_category + "/" + x + "/"
- if os.path.isdir(path):
- if fileExists(path + "plugin.pyc") or fileExists(path + "plugin.py"):
- plugin = my_import('.'.join(["Plugins", c, x, "plugin"]))
-
- if not plugin.__dict__.has_key("Plugins"):
- print "Plugin %s doesn't have 'Plugin'-call." % (x)
- continue
+ for pluginname in os_listdir(directory_category):
+ path = directory_category + "/" + pluginname
+ if os_path.isdir(path):
+ if fileExists(path + "/plugin.pyc") or fileExists(path + "/plugin.py"):
+ try:
+ plugin = my_import('.'.join(["Plugins", c, pluginname, "plugin"]))