mirror of
https://github.com/hyper-neptune/yuuki.git
synced 2024-11-15 10:54:45 +08:00
Update
This commit is contained in:
parent
b0504f844c
commit
8b6b1675ea
1 changed files with 6 additions and 3 deletions
|
@ -11,9 +11,12 @@ class Yuuki_LangSetting:
|
||||||
}
|
}
|
||||||
|
|
||||||
def gettext(self, text, lang=None):
|
def gettext(self, text, lang=None):
|
||||||
|
try:
|
||||||
if lang:
|
if lang:
|
||||||
return self.support[lang].i18nText[text]
|
return self.support[lang].i18nText[text]
|
||||||
return self.support[self.default].i18nText[text]
|
return self.support[self.default].i18nText[text]
|
||||||
|
except KeyError:
|
||||||
|
return text + "\n\n{Language Package is not Work, please inform the Admin of the Yuuki}"
|
||||||
|
|
||||||
def _(self, text, lang=None):
|
def _(self, text, lang=None):
|
||||||
return self.gettext(text, lang)
|
return self.gettext(text, lang)
|
||||||
|
|
Loading…
Reference in a new issue