Skip to content

Commit 49d6314

Browse files
authored
Merge pull request #343 from gstacks13/get_season_from_index
Get season from index instead of creating title
2 parents 7f351f4 + 77b1ee7 commit 49d6314

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

plexapi/video.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -332,9 +332,9 @@ def season(self, title=None):
332332
Parameters:
333333
title (str or int): Title or Number of the season to return.
334334
"""
335-
if isinstance(title, int):
336-
title = 'Season %s' % title if title != 0 else 'Specials'
337335
key = '/library/metadata/%s/children' % self.ratingKey
336+
if isinstance(title, int):
337+
return self.fetchItem(key, etag='Directory', index__iexact=str(title))
338338
return self.fetchItem(key, etag='Directory', title__iexact=title)
339339

340340
def episodes(self, **kwargs):

0 commit comments

Comments
 (0)