[fix] themes: run \#invoke after class constructor (#5757)

Move \#invoke into a microtask that will run after current call stack completes

Closes: https://github.com/searxng/searxng/issues/5756
This commit is contained in:
Ivan Gabaldon
2026-02-20 13:00:17 +01:00
committed by GitHub
parent 4e6e8425ca
commit 93ac6ceb35
8 changed files with 12 additions and 8 deletions
+1 -1
View File
@@ -23,7 +23,7 @@ export abstract class Plugin {
protected constructor(id: string) {
this.id = id;
void this.invoke();
queueMicrotask(() => this.invoke());
}
private async invoke(): Promise<void> {