Fix boolean default value update not updating psql default value when false (#11513)

Fixes https://github.com/twentyhq/twenty/issues/11471

## Context
When sending false as a new defaultValue, this was not going through the
migration creation code due to this condition
```typescript
if (updatableFieldInput.defaultValue)
```
This commit is contained in:
Weiko
2025-04-10 16:23:16 +02:00
committed by GitHub
parent 6f5118c677
commit d69932c6c4

View File

@ -255,9 +255,9 @@ export class FieldMetadataService extends TypeOrmQueryService<FieldMetadataEntit
}
if (
fieldMetadataInput.name ||
updatableFieldInput.options ||
updatableFieldInput.defaultValue
isDefined(fieldMetadataInput.name) ||
isDefined(updatableFieldInput.options) ||
isDefined(updatableFieldInput.defaultValue)
) {
await this.workspaceMigrationService.createCustomMigration(
generateMigrationName(`update-${updatedFieldMetadata.name}`),