Skip to content

Commit 61dc373

Browse files
authored
Fix gdm.GDM.find_by_content_type() (#668)
* Remove unused last_scan attribute of gdm.GDM * Add missing documentation of entries attribute to gdm.GDM * Fix gdm.GDM.find_by_content_type()
1 parent 1149c7f commit 61dc373

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

plexapi/gdm.py

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,14 @@
1313

1414

1515
class GDM:
16-
"""Base class to discover GDM services."""
16+
"""Base class to discover GDM services.
17+
18+
Atrributes:
19+
entries (List<dict>): List of server and/or client data discovered.
20+
"""
1721

1822
def __init__(self):
1923
self.entries = []
20-
self.last_scan = None
2124

2225
def scan(self, scan_for_clients=False):
2326
"""Scan the network."""
@@ -35,7 +38,7 @@ def find_by_content_type(self, value):
3538
"""Return a list of entries that match the content_type."""
3639
self.scan()
3740
return [entry for entry in self.entries
38-
if value in entry['data']['Content_Type']]
41+
if value in entry['data']['Content-Type']]
3942

4043
def find_by_data(self, values):
4144
"""Return a list of entries that match the search parameters."""

0 commit comments

Comments
 (0)