Skip to content

Commit bd0ed02

Browse files
committed
fix thrown error
1 parent 3c2b1bd commit bd0ed02

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/routes/configs.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,12 @@ const parseConfigs = () => {
44
const rawRobots = import.meta.env.VITE_CONFIGS;
55

66
if (!rawRobots) {
7-
throw new Error(
7+
console.warn(
88
'Cannot find configs. Please read the README.md for more info'
99
);
1010
}
1111

12-
return JSON.parse(rawRobots);
12+
return JSON.parse(rawRobots ?? {});
1313
};
1414

1515
export const dialConfigs: Record<string, DialConf> = parseConfigs();

0 commit comments

Comments
 (0)