From 2504dcc85f73af32337b031c579cc7af4c7c6bda Mon Sep 17 00:00:00 2001 From: Timon Ringwald Date: Thu, 25 Aug 2022 22:36:52 +0200 Subject: [PATCH] fixed title lang --- title_language.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/title_language.go b/title_language.go index c10c708..283e35b 100644 --- a/title_language.go +++ b/title_language.go @@ -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: