mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-05-14 04:09:29 +02:00
i18n: Add dummy language for checking translation keys (#5785)
This commit is contained in:
parent
cea08caea3
commit
42eed7dbea
5 changed files with 123 additions and 2 deletions
|
@ -26,8 +26,10 @@ func Locale(resp http.ResponseWriter, req *http.Request) translation.Locale {
|
|||
}
|
||||
}
|
||||
|
||||
// Check again in case someone changes the supported language list.
|
||||
if lang != "" && !i18n.DefaultLocales.HasLang(lang) {
|
||||
if lang == "dummy" {
|
||||
changeLang = false
|
||||
} else if lang != "" && !i18n.DefaultLocales.HasLang(lang) {
|
||||
// Check again in case someone changes the supported language list.
|
||||
lang = ""
|
||||
changeLang = false
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue