UNPKG

@flow-scanner/lightning-flow-scanner-core

Version:

A lightweight engine for Flow metadata in Node.js, and browser environments. Assess and enhance Salesforce Flow automations for best practices, security, governor limits, and performance issues.

21 lines (20 loc) 596 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); Object.defineProperty(exports, "BuildFlow", { enumerable: true, get: function() { return BuildFlow; } }); const _ConvertFlowNodes = require("./ConvertFlowNodes"); function BuildFlow(nodesToMerge) { let res = {}; for (const nodeToMerge of nodesToMerge){ const subtype = nodeToMerge.subtype; const nodesOfType = nodesToMerge.filter((node)=>subtype === node.subtype); res = (0, _ConvertFlowNodes.convertFlowNodes)(res, nodesOfType, subtype); } return res; }