Beispiel #1
0
        private Language GetLanguageByLanguageCode(string languageCode)
        {
            var lowercase = languageCode.ToLower();
            var language  = AvailableLanguages.GetAvailableLanguages().FirstOrDefault(o => o.LanguageCode.ToLower() == lowercase);

            if (language == null)
            {
                Log.Error($"|Internationalization.GetLanguageByLanguageCode|Language code can't be found <{languageCode}>");
                return(AvailableLanguages.English);
            }
            else
            {
                return(language);
            }
        }
Beispiel #2
0
 public List <Language> LoadAvailableLanguages()
 {
     return(AvailableLanguages.GetAvailableLanguages());
 }