mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 18:12:04 +00:00
feat(Set Node): Preserve binary data by default (#9668)
Co-authored-by: Michael Kret <michael.k@radency.com>
This commit is contained in:
@@ -56,13 +56,17 @@ export function composeReturnItem(
|
||||
inputItem: INodeExecutionData,
|
||||
newFields: IDataObject,
|
||||
options: SetNodeOptions,
|
||||
nodeVersion: number,
|
||||
) {
|
||||
const newItem: INodeExecutionData = {
|
||||
json: {},
|
||||
pairedItem: { item: itemIndex },
|
||||
};
|
||||
|
||||
if (options.includeBinary && inputItem.binary !== undefined) {
|
||||
const includeBinary =
|
||||
(nodeVersion >= 3.4 && !options.stripBinary && options.include !== 'none') ||
|
||||
(nodeVersion < 3.4 && !!options.includeBinary);
|
||||
if (includeBinary && inputItem.binary !== undefined) {
|
||||
// Create a shallow copy of the binary data so that the old
|
||||
// data references which do not get changed still stay behind
|
||||
// but the incoming data does not get changed.
|
||||
|
||||
Reference in New Issue
Block a user