Skip to content

Commit e35c6bc

Browse files
committed
Simplify MediaPart._buildStreams
1 parent 4780026 commit e35c6bc

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

plexapi/media.py

+2-5
Original file line numberDiff line numberDiff line change
@@ -158,11 +158,8 @@ def _loadData(self, data):
158158
self.videoProfile = data.attrib.get('videoProfile')
159159

160160
def _buildStreams(self, data):
161-
streams = []
162-
for cls in (VideoStream, AudioStream, SubtitleStream, LyricStream):
163-
items = self.findItems(data, cls, streamType=cls.STREAMTYPE)
164-
streams.extend(items)
165-
return streams
161+
""" Returns a list of :class:`~plexapi.media.MediaPartStream` objects in this MediaPart. """
162+
return self.findItems(data)
166163

167164
@property
168165
def hasPreviewThumbnails(self):

0 commit comments

Comments
 (0)