add null check

This commit is contained in:
Mads Rasmussen
2024-05-02 08:56:09 +02:00
parent 8a0775f8df
commit a910edbfce

View File

@@ -121,6 +121,7 @@ export class UmbDataTypeServerDataSource implements UmbDetailDataSource<UmbDataT
async update(model: UmbDataTypeDetailModel) {
if (!model.unique) throw new Error('Unique is missing');
if (!model.editorAlias) throw new Error('Property Editor Alias is missing');
if (!model.editorUiAlias) throw new Error('Property Editor UI Alias is missing');
// TODO: make data mapper to prevent errors
const requestBody: UpdateDataTypeRequestModel = {