fix(subsonic): someone else's private playlist reads as absent when an app tries to change it (#8021)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-26 10:22:40 -05:00
co-authored by Claude Opus 5.5
parent df2095baae
commit 1df91678ba
+5
View File
@@ -197,6 +197,11 @@ func (h *pickHandlers) ownPlaylist(w http.ResponseWriter, r *http.Request, user
} }
detail, err := h.playlists.Get(r.Context(), user.ID, id) detail, err := h.playlists.Get(r.Context(), user.ID, id)
switch { switch {
case errors.Is(err, playlists.ErrForbidden):
// Get refuses only someone else's private list, which reads as
// absent.
h.failPlaylistChange(w, r, playlists.ErrNotFound)
return nil, false
case err != nil: case err != nil:
h.failPlaylistChange(w, r, err) h.failPlaylistChange(w, r, err)
return nil, false return nil, false