Skip to content

Commit

Permalink
fix(admin-ui): Fix creating nullable string fields
Browse files Browse the repository at this point in the history
Fixes #2343
  • Loading branch information
michaelbromley committed Sep 12, 2023
1 parent bd834d0 commit 7e2c17a
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ export function getDefaultValue(type: CustomFieldType, isNullable?: boolean) {
case 'string':
case 'text':
case 'localeText':
return '';
return isNullable ? null : '';
case 'boolean':
return false;
return isNullable ? null : false;
case 'float':
case 'int':
return isNullable ? null : 0;
Expand Down

0 comments on commit 7e2c17a

Please sign in to comment.