Skip to content

Commit

Permalink
Merge pull request #4658 from node-red/fix-subflow-conf-type
Browse files Browse the repository at this point in the history
Fix saving of conf-type properties in module packaged subflows
  • Loading branch information
knolleary committed Apr 23, 2024
2 parents ac8b1e1 + e354d2c commit c9b902c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Expand Up @@ -1363,7 +1363,7 @@ RED.subflow = (function() {
break;
case "conf-types":
item.value = input.val()
item.type = data.parent.value;
item.type = "conf-type"
}
if (ui.type === "cred" || item.type !== data.parent.type || item.value !== data.parent.value) {
env.push(item);
Expand Down
2 changes: 1 addition & 1 deletion packages/node_modules/@node-red/registry/lib/subflow.js
Expand Up @@ -88,7 +88,7 @@ function generateSubflowConfig(subflow) {
this.credentials['has_' + prop.name] = (this.credentials[prop.name] !== "");
} else {
switch(prop.type) {
case "str": this[prop.name] = prop.value||""; break;
case "str": case "conf-type": this[prop.name] = prop.value||""; break;
case "bool": this[prop.name] = (typeof prop.value === 'boolean')?prop.value:prop.value === "true" ; break;
case "num": this[prop.name] = (typeof prop.value === 'number')?prop.value:Number(prop.value); break;
default:
Expand Down

0 comments on commit c9b902c

Please sign in to comment.