docs(db/m7-352): note ListPlaylistsByUserAndKind is test-only
Production list-playlists handler reuses Service.List + in-memory kind filter so other users' public playlists can surface alongside the caller's filtered own. Comment clarifies the divergence so future readers don't expect this query to be wired into the API path.
This commit is contained in:
@@ -132,7 +132,11 @@ SELECT a.cover_art_path
|
||||
DELETE FROM playlists WHERE user_id = $1 AND kind = 'system';
|
||||
|
||||
-- name: ListPlaylistsByUserAndKind :many
|
||||
-- Powers GET /api/me/playlists?kind=. Sorted by updated_at DESC.
|
||||
-- Used in integration tests; production filter applied in Go
|
||||
-- (api.handleListPlaylists fetches via Service.List and filters by Kind in
|
||||
-- memory so it can also surface other users' public playlists alongside
|
||||
-- the caller's own kind-filtered ones).
|
||||
-- Sorted by updated_at DESC.
|
||||
SELECT id, user_id, name, description, is_public, kind, system_variant,
|
||||
seed_artist_id, cover_path, track_count, duration_sec,
|
||||
created_at, updated_at
|
||||
|
||||
Reference in New Issue
Block a user