diff --git a/packages/core/src/helpers/getAttributesFromExtensions.ts b/packages/core/src/helpers/getAttributesFromExtensions.ts index 65de01adf4e..5cab0cf92ce 100644 --- a/packages/core/src/helpers/getAttributesFromExtensions.ts +++ b/packages/core/src/helpers/getAttributesFromExtensions.ts @@ -93,7 +93,11 @@ export function getAttributesFromExtensions(extensions: Extensions): ExtensionAt ...attribute, } - if (attribute?.isRequired && attribute?.default === undefined) { + if(typeof mergedAttr?.default === 'function') { + mergedAttr.default = mergedAttr.default() + } + + if (mergedAttr?.isRequired && mergedAttr?.default === undefined) { delete mergedAttr.default }