mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 18:12:04 +00:00
fix(core): Fix hasOwnProperty on augmented objects (#6124)
N8N-6333 Fixes - https://community.n8n.io/t/bug-faulty-javascript-being-implemented-in-the-code-node-after-update-to-v0-222-3/25346 - https://community.n8n.io/t/checking-for-value-in-webhook-body-with-hasownproperty/25068/11
This commit is contained in:
committed by
GitHub
parent
5974af1903
commit
206b6b90b8
@@ -143,7 +143,8 @@ export function augmentObject<T extends object>(data: T): T {
|
||||
},
|
||||
|
||||
getOwnPropertyDescriptor(target, key) {
|
||||
return Object.getOwnPropertyDescriptor(data, key) ?? defaultPropertyDescriptor;
|
||||
if (deletedProperties.indexOf(key) !== -1) return undefined;
|
||||
return Object.getOwnPropertyDescriptor(key in newData ? newData : data, key);
|
||||
},
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user