mirror of
https://github.com/vercel/commerce.git
synced 2025-07-22 20:26:49 +00:00
Updated errors
This commit is contained in:
@@ -45,13 +45,11 @@ const Navbar: FC<NavbarProps> = ({ links }) => (
|
||||
{
|
||||
console.log('Calling api')
|
||||
const response = await fetch('/api/error')
|
||||
console.log(response.status)
|
||||
if(response.status === 500) {
|
||||
console.log('Server error')
|
||||
console.log(response.ok)
|
||||
if(!response.ok) {
|
||||
Sentry.captureException("API Call to /api/error failed")
|
||||
}
|
||||
const data = response.json()
|
||||
console.log(data)
|
||||
}
|
||||
}
|
||||
>
|
||||
|
Reference in New Issue
Block a user