Fix installer breaking on setting up plugins

The entrypoint of plugins were changed in 50f12c7 and b0f6c95 but the
installer's loading of plugin info to get the correct plugin name was
not updated for these changes.  Update installer plugin loading to use
the correct entrypoint.
This commit is contained in:
Hornwitser committed 2024-01-20 01:50:42 +01:00
1 parent 671ff23085
commit 96f48ca102
1 file changed
+1 -1
+1 -1
View File
@@ -374,7 +374,7 @@ async function installClusterio(mode, plugins) {
for (let plugin of plugins) {
if (!pluginList.has(plugin)) {
// eslint-disable-next-line node/global-require
let pluginInfo = require(require.resolve(path.posix.join(plugin, "info"), { paths: [process.cwd()] }));
let pluginInfo = require(require.resolve(plugin, { paths: [process.cwd()] })).plugin;
pluginList.set(pluginInfo.name, plugin);
}
}