You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@brooklyn.apache.org by GitBox <gi...@apache.org> on 2022/07/15 09:32:36 UTC

[GitHub] [brooklyn-ui] algairim commented on a diff in pull request #351: Ffix overwrite rule when adding a config key definition

algairim commented on code in PR #351:
URL: https://github.com/apache/brooklyn-ui/pull/351#discussion_r921991674


##########
ui-modules/blueprint-composer/app/components/util/model/entity.model.js:
##########
@@ -754,7 +754,7 @@ function addConfigKeyDefinition(param, overwrite, skipUpdatesDuringBatch, value)
             delete paramMapped['default'];
         }
         // making sure we assign to empty object to avoid conflicts with config items' properties like `type`
-        allConfig[key] = Object.assign({}, configDef, paramMapped, overwrite ? null : configDef);
+        allConfig[key] = Object.assign({}, configDef, paramMapped, overwrite ? configDef: null);

Review Comment:
   This fixes the issue where constrains were not included into a config key if value was pre-populated. Thus, `regex` was ignored in validation, when switching with pre-populated value from the YAML editor to Composer.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@brooklyn.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org