Skip to content

Commit b5232d9

Browse files
authored
Merge pull request #1753 from rjmunro/rjmunro/fix-device-trigger-observer-cleanup
fix: device trigger observer crash when stopped before first reactive update
2 parents a14c7ce + 5c17586 commit b5232d9

2 files changed

Lines changed: 2 additions & 3 deletions

File tree

meteor/server/api/deviceTriggers/RundownContentObserver.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,7 @@ export class RundownContentObserver {
3333
#observers: Meteor.LiveQueryHandle[] = []
3434
#cache: ContentCache
3535
#cancelCache: () => void
36-
#cleanup: (() => void) | undefined = () => {
37-
throw new Error('RundownContentObserver.#cleanup has not been set!')
38-
}
36+
#cleanup: (() => void) | undefined
3937
#disposed = false
4038

4139
private constructor(onChanged: ChangedHandler) {

meteor/server/api/deviceTriggers/StudioObserver.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -249,5 +249,6 @@ export class StudioObserver extends EventEmitter {
249249
this.#playlistInStudioLiveQuery.stop()
250250
this.updatePlaylistInStudio.cancel()
251251
this.#rundownsLiveQuery?.stop()
252+
this.#pieceInstancesLiveQuery?.stop()
252253
}
253254
}

0 commit comments

Comments
 (0)