summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--frontend/src/plugin-loader.tsx13
1 files changed, 7 insertions, 6 deletions
diff --git a/frontend/src/plugin-loader.tsx b/frontend/src/plugin-loader.tsx
index b8729168..442db3e4 100644
--- a/frontend/src/plugin-loader.tsx
+++ b/frontend/src/plugin-loader.tsx
@@ -79,13 +79,14 @@ class PluginLoader extends Logger {
}
public async importPlugin(name: string) {
- try {
- if (this.reloadLock) {
- this.log('Reload currently in progress, adding to queue', name);
- this.pluginReloadQueue.push(name);
- return;
- }
+ if (this.reloadLock) {
+ this.log('Reload currently in progress, adding to queue', name);
+ this.pluginReloadQueue.push(name);
+ return;
+ }
+ try {
+ this.reloadLock = true;
this.log(`Trying to load ${name}`);
const oldPlugin = this.plugins.find((plugin) => plugin.name === name);