Prevent warning at startup

This commit is contained in:
Chocobozzz
2026-05-23 10:30:02 +02:00
parent 182772bb77
commit 81107dceae
2 changed files with 3 additions and 3 deletions
+2 -2
View File
@@ -304,12 +304,12 @@ export class PluginManager implements ServerHook {
this.sortHooksByPriority()
}
async removeUnsecurePluginsIfNeeded () {
async removeUnsecurePluginsIfNeededBeforeRegistration () {
for (const npmName of UNSECURE_PLUGINS_TO_REMOVE) {
const plugin = await PluginModel.loadByNpmName(npmName)
if (!plugin || plugin.uninstalled === true) continue
await this.uninstall({ npmName })
await this.uninstall({ npmName, unregister: false })
}
}
+1 -1
View File
@@ -349,7 +349,7 @@ async function startApplication () {
server.listen(port, hostname, async () => {
if (cliOptions.plugins) {
try {
await PluginManager.Instance.removeUnsecurePluginsIfNeeded()
await PluginManager.Instance.removeUnsecurePluginsIfNeededBeforeRegistration()
await PluginManager.Instance.rebuildNativePluginsIfNeeded()