mirror of
https://github.com/alextselegidis/easyappointments.git
synced 2024-11-28 10:53:40 +03:00
Show an error when using a translation key that does not exist
This commit is contained in:
parent
264328032b
commit
b15a051ee3
1 changed files with 6 additions and 1 deletions
|
@ -7,7 +7,12 @@
|
|||
return lang;
|
||||
}
|
||||
|
||||
return lang[key] || undefined;
|
||||
if (!lang[key]) {
|
||||
console.error(`Cannot find translation for requested key: "${key}"`);
|
||||
return key;
|
||||
}
|
||||
|
||||
return lang[key];
|
||||
};
|
||||
})();
|
||||
</script>
|
||||
|
|
Loading…
Reference in a new issue