mirror of
https://github.com/cpvalente/ontime.git
synced 2026-08-10 18:03:47 +00:00
fix: allow empty string as a cue value
This commit is contained in:
committed by
Carlos Valente
parent
6ffe34a642
commit
1e63238cac
@@ -9,7 +9,6 @@ import {
|
||||
isOntimeEvent,
|
||||
OntimeBlock,
|
||||
OntimeEntry,
|
||||
OntimeEvent,
|
||||
PatchWithId,
|
||||
RefetchKey,
|
||||
Rundown,
|
||||
@@ -101,11 +100,6 @@ export async function editEntry(patch: PatchWithId): Promise<OntimeEntry> {
|
||||
throw new Error('Entry not found');
|
||||
}
|
||||
|
||||
// we dont allow the user to change the cue to empty string
|
||||
if ((patch as Partial<OntimeEvent>)?.cue === '') {
|
||||
throw new Error('Cue value invalid');
|
||||
}
|
||||
|
||||
// we cannot allow patching to a different type
|
||||
if (patch?.type && currentEntry.type !== patch.type) {
|
||||
throw new Error('Invalid event type');
|
||||
|
||||
Reference in New Issue
Block a user