Skip to content

Commit

Permalink
fix: Allow usage of deprecated related artists API
Browse files Browse the repository at this point in the history
Until there is an alternative continue using it.
  • Loading branch information
hrkfdn committed Jan 20, 2025
1 parent 8dd8c9b commit f08010c
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/spotify_api.rs
Original file line number Diff line number Diff line change
Expand Up @@ -680,6 +680,7 @@ impl WebApi {

/// Get artists related to the artist with the given `id`.
pub fn artist_related_artists(&self, id: &str) -> Result<Vec<Artist>, ()> {
#[allow(deprecated)]
self.api_with_retry(|api| api.artist_related_artists(ArtistId::from_id(id).unwrap()))
.map(|fa| fa.iter().map(|a| a.into()).collect())
.ok_or(())
Expand Down

0 comments on commit f08010c

Please sign in to comment.