Skip to content

Commit

Permalink
fix(admin-ui): Fix handling of Country custom fields
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelbromley committed Nov 15, 2023
1 parent 6b31cf4 commit 3538bee
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,11 @@ export function addCustomFields(documentNode: DocumentNode, customFields: Custom
entityType = 'Address';
}

if (entityType === ('Country' as any)) {
// Country is an alias of Region
entityType = 'Region';
}

const customFieldsForType = customFields[entityType];
if (customFieldsForType && customFieldsForType.length) {
(fragmentDef.selectionSet.selections as SelectionNode[]).push({
Expand Down

0 comments on commit 3538bee

Please sign in to comment.