mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 10:02:05 +00:00
🐛 Fix issue that it did export default parameter values if they were
objects
This commit is contained in:
@@ -21,7 +21,7 @@ import {
|
||||
Workflow
|
||||
} from './Workflow';
|
||||
|
||||
import { get } from 'lodash';
|
||||
import { get, isEqual } from 'lodash';
|
||||
|
||||
|
||||
|
||||
@@ -585,7 +585,9 @@ export function getNodeParameters(nodePropertiesArray: INodeProperties[], nodeVa
|
||||
nodeParameters[nodeProperties.name] = nodeValues[nodeProperties.name] || nodeProperties.default;
|
||||
}
|
||||
nodeParametersFull[nodeProperties.name] = nodeParameters[nodeProperties.name];
|
||||
} else if (nodeValues[nodeProperties.name] !== nodeProperties.default || (nodeValues[nodeProperties.name] !== undefined && parentType === 'collection')) {
|
||||
} else if ((nodeValues[nodeProperties.name] !== nodeProperties.default && typeof nodeValues[nodeProperties.name] !== 'object') ||
|
||||
(typeof nodeValues[nodeProperties.name] === 'object' && !isEqual(nodeValues[nodeProperties.name], nodeProperties.default)) ||
|
||||
(nodeValues[nodeProperties.name] !== undefined && parentType === 'collection')) {
|
||||
// Set only if it is different to the default value
|
||||
nodeParameters[nodeProperties.name] = nodeValues[nodeProperties.name];
|
||||
nodeParametersFull[nodeProperties.name] = nodeParameters[nodeProperties.name];
|
||||
|
||||
Reference in New Issue
Block a user