Fix GetNowPlaying endpoint showing only the last play

This commit is contained in:
Deluan
2021-06-20 10:36:50 -04:00
parent f8ee6db72a
commit 97434c1789
12 changed files with 110 additions and 31 deletions
+2 -2
View File
@@ -7,7 +7,7 @@ import (
type Player struct {
ID string `json:"id" orm:"column(id)"`
Name string `json:"name"`
Type string `json:"type"`
UserAgent string `json:"userAgent"`
UserName string `json:"userName"`
Client string `json:"client"`
IPAddress string `json:"ipAddress"`
@@ -21,6 +21,6 @@ type Players []Player
type PlayerRepository interface {
Get(id string) (*Player, error)
FindByName(client, userName string) (*Player, error)
FindMatch(userName, client, typ string) (*Player, error)
Put(p *Player) error
}