diff options
| author | Florian Fischer <florian.fischer@muhq.space> | 2023-05-21 17:50:51 +0200 |
|---|---|---|
| committer | Florian Fischer <florian.fischer@muhq.space> | 2023-05-21 17:50:51 +0200 |
| commit | eb76608e7287db4b26d877deccce138daee849da (patch) | |
| tree | 9117519023cf91b48cbcb28e69be90e0f16b345b /backend.go | |
| parent | 0db007609efb842f43d837988eff15b31765f615 (diff) | |
| download | WRMS-eb76608e7287db4b26d877deccce138daee849da.tar.gz WRMS-eb76608e7287db4b26d877deccce138daee849da.zip | |
add OnSongFinished backend hook allowing to remove uploaded songs
Diffstat (limited to 'backend.go')
| -rw-r--r-- | backend.go | 7 |
1 files changed, 3 insertions, 4 deletions
@@ -8,15 +8,14 @@ import ( type Backend interface { Play(song *Song, player *Player) Search(keyword string) []Song + OnSongFinished(song *Song) } type DummyBackend struct{} -func (dummy *DummyBackend) Play(song *Song, player *Player) { -} - +func (dummy *DummyBackend) Play(song *Song, player *Player) {} +func (dummy *DummyBackend) OnSongFinished(song *Song) {} func (dummy *DummyBackend) Search(keyword string) []Song { - s := NewDummySong("Dummy Mc Crashtest", "exactly "+keyword) return []Song{s} } |
