Restore deprecated Collection.children

This commit is contained in:
JonnyWong16 2020-12-13 11:59:37 -08:00
parent 8958aea67f
commit 4a3d7db9fa
No known key found for this signature in database
GPG key ID: B1F1F9807184697A

View file

@ -1478,6 +1478,10 @@ class Collections(PlexPartialObject):
self.type = data.attrib.get('type')
self.updatedAt = utils.toDatetime(data.attrib.get('updatedAt'))
@property
def children(self):
return self.fetchItems(self.key)
def items(self):
""" Returns a list of all items in the collection. """
key = '/library/metadata/%s/children' % self.ratingKey