diff --git a/src/Umbraco.Web.UI.Client/src/backoffice/documents/documents/entity-actions/save-document.entity-action.ts b/src/Umbraco.Web.UI.Client/src/backoffice/documents/documents/entity-actions/save-document.entity-action.ts index a6a4e594fa..83bc7418ea 100644 --- a/src/Umbraco.Web.UI.Client/src/backoffice/documents/documents/entity-actions/save-document.entity-action.ts +++ b/src/Umbraco.Web.UI.Client/src/backoffice/documents/documents/entity-actions/save-document.entity-action.ts @@ -6,7 +6,7 @@ export class SaveDocumentEntityAction { #host: UmbControllerHostInterface; #key: string; #documentRepository: UmbDocumentRepository; - #workspaceContext: any; + #workspaceContext?: any; constructor(host: UmbControllerHostInterface, key: string) { this.#host = host; @@ -19,6 +19,7 @@ export class SaveDocumentEntityAction { } async execute() { + if (!this.#workspaceContext) return; // TODO: it doesn't get the updated value const document = this.#workspaceContext.getData(); this.#documentRepository.saveDetail(document);