Skip to content

Commit

Permalink
Update index.js
Browse files Browse the repository at this point in the history
  • Loading branch information
Starman3787 committed Oct 22, 2024
1 parent 1e0cf29 commit 2ade833
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ export const getQuarkLocaleCode = (language) => {

export const getDatabaseLocaleCode = (language) => {
const toReturn = locales[language]?.id;
if (!toReturn) throw new Error(`Language ${language} not found`);
if (typeof toReturn !== "number") throw new Error(`Language ${language} not found`);
return toReturn;
};

Expand Down

0 comments on commit 2ade833

Please sign in to comment.