From e2b7043d3c7a89be0d4a9c096417939810f84929 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Niels=20Lyngs=C3=B8?= Date: Tue, 30 Jun 2020 15:59:06 +0200 Subject: [PATCH] check for $block.data, to verify that the blockObject is not in a destroyed state. --- .../blocklist/umbBlockListPropertyEditor.component.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/blocklist/umbBlockListPropertyEditor.component.js b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/blocklist/umbBlockListPropertyEditor.component.js index 880334a7b3..9ed28cdee5 100644 --- a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/blocklist/umbBlockListPropertyEditor.component.js +++ b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/blocklist/umbBlockListPropertyEditor.component.js @@ -135,7 +135,8 @@ // Append the blockObjects to our layout. vm.layout.forEach(entry => { - if (entry.$block === undefined || entry.$block === null) { + // $block must have the data property to be a valid BlockObject, if not its concidered as a destroyed blockObject. + if (entry.$block === undefined || entry.$block === null || entry.$block.data === undefined) { var block = getBlockObject(entry); // If this entry was not supported by our property-editor it would return 'null'.