Skip to content

Commit

Permalink
Merge pull request #15241 from GitStartHQ/fix/content-manager-crash-o…
Browse files Browse the repository at this point in the history
…n-nonstring-dynamicfield

fix: Content manager crashing when dynamic zone entry field is not of type string
  • Loading branch information
gu-stav committed Dec 23, 2022
2 parents 05be584 + c078ac2 commit b767d40
Showing 1 changed file with 1 addition and 1 deletion.
Expand Up @@ -73,7 +73,7 @@ const DynamicZoneComponent = ({

const mainField = get(modifiedData, [name, index, mainFieldKey]) ?? '';

const displayedValue = mainFieldKey === 'id' ? '' : mainField.trim();
const displayedValue = mainFieldKey === 'id' ? '' : String(mainField).trim();

const mainValue = displayedValue.length > 0 ? ` - ${displayedValue}` : displayedValue;

Expand Down

0 comments on commit b767d40

Please sign in to comment.