Keepalive must return an ID to be used with `dataProvider.getOne`

This commit is contained in:
Deluan 2021-04-26 23:14:28 -04:00
parent 616a44bac4
commit 125c4fe5ec
1 changed files with 3 additions and 1 deletions

View File

@ -69,7 +69,9 @@ func (app *Router) routes(path string) http.Handler {
app.addPlaylistTrackRoute(r)
// Keepalive endpoint to be used to keep the session valid (ex: while playing songs)
r.Get("/keepalive/*", func(w http.ResponseWriter, r *http.Request) { _, _ = w.Write([]byte(`{"response":"ok"}`)) })
r.Get("/keepalive/*", func(w http.ResponseWriter, r *http.Request) {
_, _ = w.Write([]byte(`{"response":"ok", "id":"keepalive"}`))
})
if conf.Server.DevActivityPanel {
r.Handle("/events", app.broker)