mirror of
https://github.com/cheeaun/phanpy.git
synced 2025-01-22 16:46:28 +01:00
Instead of return false, return the default locale arg
This commit is contained in:
parent
a382efee5b
commit
ac8a4c7fbf
1 changed files with 2 additions and 1 deletions
|
@ -6,7 +6,8 @@ function _localeMatch(...args) {
|
|||
try {
|
||||
return match(...args);
|
||||
} catch (e) {
|
||||
return false;
|
||||
const defaultLocale = args[2];
|
||||
return defaultLocale || false;
|
||||
}
|
||||
}
|
||||
const localeMatch = mem(_localeMatch, {
|
||||
|
|
Loading…
Reference in a new issue