String() method improved

This commit is contained in:
Timon Ringwald 2022-08-21 14:38:44 +02:00
parent d99c281ab5
commit 80d7a2f422

View File

@ -22,11 +22,12 @@ type ParsedTorrent struct {
} }
func (t ParsedTorrent) String() string { func (t ParsedTorrent) String() string {
return fmt.Sprintf("title: %s | episode: %d | resolution: %s | languages: %s | subtitles: %s", return fmt.Sprintf("title: %s | episode: %d | resolution: %s | languages: %s | subtitles: %s | %s",
t.Anime.Title.Native, t.Anime.Title.Native,
t.Episode, t.Episode,
t.Resolution, t.Resolution,
strings.Join(t.Languages, ", "), strings.Join(t.Languages, ", "),
strings.Join(t.Subtitles, ", "), strings.Join(t.Subtitles, ", "),
t.Torrent,
) )
} }