server/lastfm: make a scrobbler interface and migrate lastfm to use it

This commit is contained in:
Alex McGrath
2021-01-08 13:09:42 +00:00
committed by Senan Kelly
parent cc93d61908
commit f4ff7e70f2
5 changed files with 38 additions and 12 deletions

View File

@@ -4,6 +4,10 @@ import (
"encoding/xml"
)
type Scrobbler interface {
Scrobble(interface{}, ScrobbleOptions) error
}
type LastFM struct {
XMLName xml.Name `xml:"lfm"`
Status string `xml:"status,attr"`