mirror of
https://github.com/getgrav/grav-plugin-admin.git
synced 2026-01-06 15:43:01 +01:00
Fallback to default lang if no string is found
This commit is contained in:
@@ -716,6 +716,10 @@ class Admin
|
||||
foreach ((array)$languages as $lang) {
|
||||
$translation = $this->grav['language']->getTranslation($lang, $lookup, $array_support);
|
||||
|
||||
if (!$translation) {
|
||||
$translation = $this->grav['language']->getTranslation($this->grav['language']->getDefault(), $lookup, $array_support);
|
||||
}
|
||||
|
||||
if ($translation) {
|
||||
if (count($args) >= 1) {
|
||||
return vsprintf($translation, $args);
|
||||
|
||||
@@ -1277,4 +1277,4 @@ de:
|
||||
SAVE_AS: Save as
|
||||
MODAL_DELETE_PAGE_CONFIRMATION_REQUIRED_DESC: Are you sure you want to delete this page and all it's children? If the page is translated in other languages, those translations will be kept and must be deleted separately. This action cannot be undone.
|
||||
AND: und
|
||||
UPDATE_AVAILABLE: Update available
|
||||
UPDATE_AVAILABLE: Aktualisierung verfügbar
|
||||
|
||||
Reference in New Issue
Block a user