fix plugin_order
This commit is contained in:
parent
c06bdf0491
commit
51387c31c4
@ -513,12 +513,17 @@ class PluginManager(metaclass=Singleton):
|
|||||||
# 作者链接
|
# 作者链接
|
||||||
if hasattr(plugin_class, "author_url"):
|
if hasattr(plugin_class, "author_url"):
|
||||||
plugin.author_url = plugin_class.author_url
|
plugin.author_url = plugin_class.author_url
|
||||||
|
# 加载顺序
|
||||||
|
if hasattr(plugin_class, "plugin_order"):
|
||||||
|
plugin.plugin_order = plugin_class.plugin_order
|
||||||
# 是否需要更新
|
# 是否需要更新
|
||||||
plugin.has_update = False
|
plugin.has_update = False
|
||||||
# 本地标志
|
# 本地标志
|
||||||
plugin.is_local = True
|
plugin.is_local = True
|
||||||
# 汇总
|
# 汇总
|
||||||
plugins.append(plugin)
|
plugins.append(plugin)
|
||||||
|
# 根据加载排序重新排序
|
||||||
|
plugins.sort(key=lambda x: x.plugin_order if hasattr(x, "plugin_order") else 0)
|
||||||
return plugins
|
return plugins
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
|
Loading…
x
Reference in New Issue
Block a user