From f17e2478e2e73004a9efa82c01256c6c9e1fd0f1 Mon Sep 17 00:00:00 2001 From: Andrew Kingston Date: Thu, 25 Mar 2021 16:17:56 +0000 Subject: [PATCH] Fix crash generating bindable properties for an empty data provider ID --- packages/builder/src/builderStore/dataBinding.js | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/packages/builder/src/builderStore/dataBinding.js b/packages/builder/src/builderStore/dataBinding.js index 1d23c8f488..d68b0868e2 100644 --- a/packages/builder/src/builderStore/dataBinding.js +++ b/packages/builder/src/builderStore/dataBinding.js @@ -366,10 +366,7 @@ function bindingReplacement(bindableProperties, textWithBindings, convertTo) { * {{ literal [componentId] }} */ function extractLiteralHandlebarsID(value) { - if (!value) { - return null - } - return value.match(/{{\s*literal[\s\[]+([a-fA-F0-9]+)[\s\]]*}}/)[1] + return value?.match(/{{\s*literal[\s\[]+([a-fA-F0-9]+)[\s\]]*}}/)?.[1] } /**