Skip to content

Commit 3edfcd8

Browse files
committed
fix(LSG): don't return null for packageName
1 parent 14696fd commit 3edfcd8

File tree

2 files changed

+4
-6
lines changed

2 files changed

+4
-6
lines changed

packages/live-status-gateway/api/schemas/packages.yaml

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,7 @@ $defs:
2929
properties:
3030
packageName:
3131
description: Name of the package
32-
oneOf:
33-
- type: string
34-
- type: 'null'
32+
type: string
3533
statusCode:
3634
description: Status code
3735
type: number
@@ -53,7 +51,7 @@ $defs:
5351
previewUrl:
5452
description: URL where the preview can be accessed
5553
type: string
56-
required: [packageName, statusCode, rundownId, pieceId]
54+
required: [statusCode, rundownId, pieceId]
5755
additionalProperties: false
5856
examples:
5957
- packageName: 'MV000123.mxf'

packages/live-status-gateway/src/topics/packagesTopic.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import { CollectionHandlers } from '../liveStatusServer'
1010
const THROTTLE_PERIOD_MS = 200
1111

1212
interface PackageStatus {
13-
packageName: string | null
13+
packageName?: string
1414
statusCode: PieceStatusCode
1515

1616
rundownId: string
@@ -49,7 +49,7 @@ export class PackagesTopic extends WebSocketTopicBase implements WebSocketTopic
4949
event: 'packages',
5050
rundownPlaylistId: this._activePlaylist ? unprotectString(this._activePlaylist._id) : null,
5151
packages: this._pieceContentStatuses.map((contentStatus) => ({
52-
packageName: contentStatus.status.packageName,
52+
packageName: contentStatus.status.packageName ?? undefined,
5353
statusCode: contentStatus.status.status,
5454
pieceId: unprotectString(contentStatus.pieceId),
5555
rundownId: unprotectString(contentStatus.rundownId),

0 commit comments

Comments
 (0)