fix: break the switch statement for proper logs

This commit is contained in:
Michael Zetterberg
2024-08-29 14:29:58 +02:00
parent 3a88b35a77
commit bb93d488bb

View File

@@ -46,10 +46,13 @@ export default async function ProtectedLayout({
redirect(redirectURL) redirect(redirectURL)
case "notfound": case "notfound":
console.error(`[layout:protected] notfound user loading error`) console.error(`[layout:protected] notfound user loading error`)
break
case "unknown": case "unknown":
console.error(`[layout:protected] unknown user loading error`) console.error(`[layout:protected] unknown user loading error`)
break
default: default:
console.error(`[layout:protected] unhandled user loading error`) console.error(`[layout:protected] unhandled user loading error`)
break
} }
return <p>Something went wrong!</p> return <p>Something went wrong!</p>
} }