Skip to content

Commit 1039df1

Browse files
authored
Apply suggestions from code review
1 parent 9205739 commit 1039df1

1 file changed

Lines changed: 6 additions & 3 deletions

File tree

packages/app/src/cli/services/generate/fetch-extension-specifications.ts

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,11 @@ export async function fetchSpecifications({
4646
// Hardcoded value for the post purchase extension because the value is wrong in the API
4747
if (spec.identifier === 'checkout_post_purchase') spec.surface = 'post_purchase'
4848

49-
// Hardcoded value for the webhook_subscription extension because the value is wrong in the API
50-
if (spec.identifier === 'webhook_subscription') spec.experience = 'configuration'
49+
// Hardcoded values for the webhook_subscription extension because the values are wrong in the API
50+
if (spec.identifier === 'webhook_subscription') {
51+
spec.experience = 'configuration'
52+
spec.uidStrategy = 'dynamic'
53+
}
5154

5255
return spec
5356
})
@@ -126,7 +129,7 @@ function mergeLocalAndRemoteSpec(
126129
experience: remoteSpec.experience as 'extension' | 'configuration',
127130
registrationLimit: remoteSpec.registrationLimit,
128131
uidStrategy: remoteSpec.uidStrategy,
129-
surface: remoteSpec.surface ?? '',
132+
surface: remoteSpec.surface ?? localSpec.surface,
130133
}
131134
return merged
132135
}

0 commit comments

Comments
 (0)