diff --git a/index.js b/index.js index 268f28d..3b43b03 100644 --- a/index.js +++ b/index.js @@ -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; };