From b40eb3405e2aebd7522241a21125a244d69816c9 Mon Sep 17 00:00:00 2001 From: Chrystian Huot Date: Mon, 8 Jun 2020 11:17:10 -0400 Subject: [PATCH] Don't emit call queue length when idling --- .../src/app/components/rdio-scanner/rdio-scanner.service.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/client/src/app/components/rdio-scanner/rdio-scanner.service.ts b/client/src/app/components/rdio-scanner/rdio-scanner.service.ts index b377ec4..b84038c 100644 --- a/client/src/app/components/rdio-scanner/rdio-scanner.service.ts +++ b/client/src/app/components/rdio-scanner/rdio-scanner.service.ts @@ -357,7 +357,9 @@ export class AppRdioScannerService implements OnDestroy { if (call?.audio && this.liveFeedMap && this.liveFeedMap[sys] && this.liveFeedMap[sys][tg]) { this.callQueue.push(call); - this.event.emit({ queue: this.callQueue.length }); + if (this.call) { + this.event.emit({ queue: this.callQueue.length }); + } this.play(); }