Skip to content

Commit

Permalink
chore: kindful warning message for enduser
Browse files Browse the repository at this point in the history
  • Loading branch information
tarunama committed Jan 17, 2021
1 parent fea0ac1 commit 119d1d2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/next/next-server/server/api-utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,7 @@ export function tryGetPreviewData(
try {
cookies = getCookies()
} catch {
console.warn('Did not get data from NextApiRequestCookies')
console.warn('If you have not enabled cookies, please do so.')
return false
}

Expand Down Expand Up @@ -340,7 +340,7 @@ export function tryGetPreviewData(
options.previewModeSigningKey
) as typeof encryptedPreviewData
} catch (e) {
console.warn(`Failed to veriry jsonwebtoken: ${e}`)
// TODO: warn
clearPreviewData(res as NextApiResponse)
return false
}
Expand Down

0 comments on commit 119d1d2

Please sign in to comment.