Skip to content

Commit

Permalink
use tiny-invariant
Browse files Browse the repository at this point in the history
  • Loading branch information
codeincontext committed Oct 29, 2024
1 parent dd2668e commit bc57726
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions packages/logger/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,7 @@ import debug from "debug";
import structuredLogger, { StructuredLogger } from "./structuredLogger";

if (typeof window !== "undefined") {
if (!process.env.NEXT_PUBLIC_DEBUG) {
throw new Error("NEXT_PUBLIC_DEBUG is not set");
}
invariant(process.env.NEXT_PUBLIC_DEBUG, "NEXT_PUBLIC_DEBUG is not set");
debug.enable(process.env.NEXT_PUBLIC_DEBUG);
}

Expand Down

0 comments on commit bc57726

Please sign in to comment.