better warn message

pull/3312/head
babakfp 2 years ago
parent 815e41badb
commit 0d6f340ddd

@ -213,7 +213,7 @@ export function createRouter(
if (!failedLangFallbackLang) return if (!failedLangFallbackLang) return
if (!langNames.includes(failedLangFallbackLang)) { if (!langNames.includes(failedLangFallbackLang)) {
console.warn( console.warn(
`Invalid value received in "VitePress Config" > "locales.${failedLang}.fallback"! "${failedLangFallbackLang}" is not a valid value.` `Invalid value received in "VitePress Config" > "locales.${failedLang}.fallback". "${failedLangFallbackLang}" is not a valid value.`
) )
return return
} }
@ -236,7 +236,7 @@ export function createRouter(
if (!fallbackLang) return if (!fallbackLang) return
if (!langNames.includes(fallbackLang)) { if (!langNames.includes(fallbackLang)) {
console.warn( console.warn(
`Invalid value received in "VitePress Config" > "locales.root.fallback"! "${fallbackLang}" is not a valid value.` `Invalid value received in "VitePress Config" > "locales.root.fallback". "${fallbackLang}" is not a valid value.`
) )
return return
} }

Loading…
Cancel
Save