mirror of
https://github.com/strapi/strapi.git
synced 2025-09-25 16:29:34 +00:00
Update comment
This commit is contained in:
parent
caa4720005
commit
101b1072c2
@ -146,7 +146,7 @@ const GenericInput = ({
|
||||
hint={hint}
|
||||
required={required}
|
||||
onChange={(json) => {
|
||||
// Default to null when the field is required and there is no input value
|
||||
// Default to null when the field is not required and there is no input value
|
||||
const value = !attribute.required && !json.length ? 'null' : json;
|
||||
onChange({ target: { name, value } });
|
||||
}}
|
||||
|
Loading…
x
Reference in New Issue
Block a user