mirror of
https://github.com/navidrome/navidrome.git
synced 2025-06-04 01:21:19 +03:00
Fix getSongsByGenre pagination. Fix #1640
This commit is contained in:
parent
ddfde7bfc8
commit
ecac74c2bd
@ -182,7 +182,7 @@ func (api *Router) GetRandomSongs(r *http.Request) (*responses.Subsonic, error)
|
|||||||
|
|
||||||
func (api *Router) GetSongsByGenre(r *http.Request) (*responses.Subsonic, error) {
|
func (api *Router) GetSongsByGenre(r *http.Request) (*responses.Subsonic, error) {
|
||||||
count := number.Min(utils.ParamInt(r, "count", 10), 500)
|
count := number.Min(utils.ParamInt(r, "count", 10), 500)
|
||||||
offset := number.Min(utils.ParamInt(r, "offset", 0), 500)
|
offset := utils.ParamInt(r, "offset", 0)
|
||||||
genre := utils.ParamString(r, "genre")
|
genre := utils.ParamString(r, "genre")
|
||||||
|
|
||||||
songs, err := api.getSongs(r.Context(), offset, count, filter.SongsByGenre(genre))
|
songs, err := api.getSongs(r.Context(), offset, count, filter.SongsByGenre(genre))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user