Register subflow module instance node with parent flow

Fixes #3798
This commit is contained in:
Nick O'Leary 2022-08-02 00:05:21 +01:00
parent dc7fef6395
commit 5c29feec63
No known key found for this signature in database
GPG Key ID: 4F2157149161A6C9
1 changed files with 4 additions and 2 deletions

View File

@ -134,10 +134,12 @@ function createNode(flow,config) {
subflowInstanceConfig,
instanceConfig
);
// Register this subflow as an instance node of the parent flow.
// This allows nodes inside the subflow to get ahold of each other
// such as a node accessing its config node
flow.subflowInstanceNodes[config.id] = subflow
subflow.start();
return subflow.node;
Log.error(Log._("nodes.flow.unknown-type", {type:type}));
}
} catch(err) {
Log.error(err);