From 283c35f59243cafe743fc21da10abc6a4268e12b Mon Sep 17 00:00:00 2001 From: jsundram Date: Wed, 3 Jun 2015 21:16:12 -0700 Subject: [PATCH] offset/limit only makes sense for album_tracks --- CHANGES.txt | 2 +- README.md | 2 +- spotipy/client.py | 6 ++---- 3 files changed, 4 insertions(+), 6 deletions(-) diff --git a/CHANGES.txt b/CHANGES.txt index 2795680..b46e2c9 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -13,4 +13,4 @@ v2.310, August 20, 2014 -- Added playlist replace and remove methods. Added auth v2.310, January 5, 2015 -- Added session support v2.3.1, March 28, 2015 -- Auto retry support v2.3.5, April 28, 2015 -- Fixed bug in auto retry support -v2.3.6, June 3, 2015 -- Support for offset/limit with album/album_tracks API +v2.3.6, June 3, 2015 -- Support for offset/limit with album_tracks API diff --git a/README.md b/README.md index 1c0782a..27524a6 100644 --- a/README.md +++ b/README.md @@ -68,4 +68,4 @@ If you have suggestions, bugs or other issues specific to this library, file the - v2.3.2 - March 31, 2015 -- Added auto retry logic - v2.3.3 - April 1, 2015 -- added client credential flow - v2.3.5 - April 28, 2015 -- Fixed bug in auto retry logic -- v2.3.6 - June 3, 2015 -- Support for offset/limit with album/album_tracks API +- v2.3.6 - June 3, 2015 -- Support for offset/limit with album_tracks API diff --git a/spotipy/client.py b/spotipy/client.py index b1dd7ac..5c2ff21 100644 --- a/spotipy/client.py +++ b/spotipy/client.py @@ -254,17 +254,15 @@ class Spotify(object): trid = self._get_id('artist', artist_id) return self._get('artists/' + trid + '/related-artists') - def album(self, album_id, limit=50, offset=0): + def album(self, album_id): ''' returns a single album given the album's ID, URIs or URL Parameters: - album_id - the album ID, URI or URL - - limit - the number of items to return - - offset - the index of the first item to return ''' trid = self._get_id('album', album_id) - return self._get('albums/' + trid, limit=limit, offset=offset) + return self._get('albums/' + trid) def album_tracks(self, album_id, limit=50, offset=0): ''' Get Spotify catalog information about an album's tracks