diff --git a/CHANGELOG.md b/CHANGELOG.md index e69de29bb2d..79aacc3c1c5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -0,0 +1 @@ +- Fix blocking functions in the emulator when using multiple codebases (#6504). diff --git a/src/emulator/functionsEmulator.ts b/src/emulator/functionsEmulator.ts index be2ec1df96c..5acff45684f 100644 --- a/src/emulator/functionsEmulator.ts +++ b/src/emulator/functionsEmulator.ts @@ -566,8 +566,6 @@ export class FunctionsEmulator implements EmulatorInstance { } else { this.workerPools[emulatableBackend.codebase].refresh(); } - // reset blocking functions config for reloads - this.blockingFunctionsConfig = {}; // When force is true we set up all triggers, otherwise we only set up // triggers which have a unique function name @@ -1436,6 +1434,8 @@ export class FunctionsEmulator implements EmulatorInstance { async reloadTriggers() { this.triggerGeneration++; + // reset blocking functions config for reloads + this.blockingFunctionsConfig = {}; for (const backend of this.args.emulatableBackends) { await this.loadTriggers(backend); }