fixed title lang

This commit is contained in:
Timon Ringwald 2022-08-25 22:36:52 +02:00
parent caabe20b31
commit 2504dcc85f

View File

@ -18,7 +18,7 @@ const (
func ParseAnimeTitleLang(str string) (AnimeTitleLang, error) {
lang := AnimeTitleLang(strings.TrimSpace(str))
switch AnimeTitleLangEnglish {
switch lang {
case AnimeTitleLangEnglish:
return lang, nil
case AnimeTitleUserPreferred:
@ -33,7 +33,7 @@ func ParseAnimeTitleLang(str string) (AnimeTitleLang, error) {
}
func (atl AnimeTitleLang) GetTitle(anime *anilist.Media) string {
switch AnimeTitleLangEnglish {
switch atl {
case AnimeTitleLangEnglish:
return anime.Title.English
case AnimeTitleUserPreferred: