Skip to content

Commit

Permalink
fix: error when code is undefined
Browse files Browse the repository at this point in the history
  • Loading branch information
yongenaelf committed Nov 13, 2024
1 parent ac68c1c commit fc283f7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion components/workspace/format-errors.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ function ErrorTypeLink({ type }: { type: string }) {

if (kind === "warning") return <Badge variant="secondary">warning</Badge>;

if (kind === "error" && code.startsWith("CS"))
if (kind === "error" && code?.startsWith("CS"))
return (
<Link
className={badgeVariants({
Expand Down

0 comments on commit fc283f7

Please sign in to comment.