fix(Set Node): Null should not throw an error (#7416)

Github issue / Community forum post (link here to close automatically):
This commit is contained in:
Michael Kret
2023-10-12 18:07:12 +03:00
committed by GitHub
parent 46977a2aff
commit e9b6ab04cd
5 changed files with 258 additions and 3 deletions

View File

@@ -163,6 +163,11 @@ export const validateEntry = (
) => {
let entryValue = entry[entry.type];
const name = entry.name;
if (nodeVersion && nodeVersion >= 3.2 && (entryValue === undefined || entryValue === null)) {
return { name, value: null };
}
const entryType = entry.type.replace('Value', '') as FieldType;
const description = `To fix the error try to change the type for the field "${name}" or activate the option “Ignore Type Conversion Errors” to apply a less strict type validation`;