mirror of
https://github.com/clusterio/clusterio.git
synced 2026-11-23 00:13:13 +09:00
Add checkEnabled and rename plugin loading files
plugins.checkEnabled(name) tells if a plugin is in the load list. #plugin_module is renamed to #import_plugin. loadPluginMigrations moves into PluginLoader.ts, leaving plugin_loader.ts with plugin discovery and details, so it is renamed to plugin_info.ts. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
68c5ea82e7
commit
47c84fc289
12 files changed
+118
-101
No files matched your search
@@ -239,7 +239,8 @@ If the plugin is already loaded it resolves right away.
|
||||
If the plugin is not installed, has load_plugin set to false, is disabled by recovery mode, or fails to load, it resolves to undefined right away.
|
||||
If it times out it resolves to undefined.
|
||||
In both cases a warning naming both plugins is logged.
|
||||
`plugins.checkInstalled(name)` tells if a plugin is installed, use it to avoid the warning for optional plugins.
|
||||
`plugins.checkInstalled(name)` tells if a plugin is installed, and `plugins.checkEnabled(name)` tells if it is being loaded alongside yours.
|
||||
Use `checkEnabled` to avoid the warning for optional plugins.
|
||||
|
||||
Startup does not continue until every entrypoint has returned.
|
||||
Two plugins awaiting each other in their entrypoints hold up startup until one of them times out.
|
||||
|
||||
Reference in new issue
Block a user