[GH-ISSUE #275] replacePlaylistTracks tests for wrong response status #203

Closed
opened 2026-02-27 19:26:35 +03:00 by kerem · 2 comments
Owner

Originally created by @cdarken on GitHub (May 13, 2024).
Original GitHub issue: https://github.com/jwilsson/spotify-web-api-php/issues/275

Hi. I've been using your library, it works great!
But when updating a playlist I noticed the return false when actually I see the playlist updating.
The cause is the comparation with 201 of the response status in replacePlaylistTracks in src/SpotifyWebAPI.php when the Spotify api docs specify a 200 response in case of success (https://developer.spotify.com/documentation/web-api/reference/reorder-or-replace-playlists-tracks)

Originally created by @cdarken on GitHub (May 13, 2024). Original GitHub issue: https://github.com/jwilsson/spotify-web-api-php/issues/275 Hi. I've been using your library, it works great! But when updating a playlist I noticed the return false when actually I see the playlist updating. The cause is the comparation with 201 of the response status in `replacePlaylistTracks` in `src/SpotifyWebAPI.php` when the Spotify api docs specify a 200 response in case of success (`https://developer.spotify.com/documentation/web-api/reference/reorder-or-replace-playlists-tracks`)
kerem 2026-02-27 19:26:35 +03:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@jwilsson commented on GitHub (May 13, 2024):

Hey!
It does indeed! Spotify must have changed that at some point 🤔 I'll get that sorted straight away.

<!-- gh-comment-id:2108244972 --> @jwilsson commented on GitHub (May 13, 2024): Hey! It does indeed! Spotify must have changed that at some point 🤔 I'll get that sorted straight away.
Author
Owner

@jwilsson commented on GitHub (May 13, 2024):

6.0.4 fixes it, thanks for the report!

<!-- gh-comment-id:2108253533 --> @jwilsson commented on GitHub (May 13, 2024): `6.0.4` fixes it, thanks for the report!
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/spotify-web-api-php#203
No description provided.