Skip to content

Commit

Permalink
Enhance readability of error message
Browse files Browse the repository at this point in the history
  • Loading branch information
frandiox committed Sep 18, 2024
1 parent 1341fd8 commit 68a3079
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions packages/theme/src/cli/utilities/theme-environment/html.ts
Original file line number Diff line number Diff line change
Expand Up @@ -120,10 +120,12 @@ function assertThemeId(response: Response, html: string, expectedThemeId: string
if (obtainedThemeId && obtainedThemeId !== expectedThemeId) {
renderFatalError(
new AbortError(
`Theme ID mismatch: expected ${expectedThemeId} but got ${obtainedThemeId}.\nRequest ID: ${response.headers.get(
'x-request-id',
)}\nURL: ${response.url}`,
`This is likely related to an issue in upstream Shopify APIs.\nPlease try again in a few minutes and report this issue:\nhttps://github.com/Shopify/cli/issues/new?template=bug-report.yml`,
`Theme ID mismatch: expected ${expectedThemeId} but got ${obtainedThemeId}.` +
`\nRequest ID: ${response.headers.get('x-request-id')}` +
`\nURL: ${response.url}`,
`This is likely related to an issue in upstream Shopify APIs.` +
`\nPlease try again in a few minutes and report this issue:` +
`\nhttps://github.com/Shopify/cli/issues/new?template=bug-report.yml`,
),
)

Expand Down

0 comments on commit 68a3079

Please sign in to comment.