Skip to content

Commit 650fbac

Browse files
authored
Remove extending from (object), not needed in Python 3 (#943)
1 parent f16058f commit 650fbac

File tree

5 files changed

+21
-21
lines changed

5 files changed

+21
-21
lines changed

plexapi/base.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
}
3232

3333

34-
class PlexObject(object):
34+
class PlexObject:
3535
""" Base class for all Plex objects.
3636
3737
Parameters:
@@ -649,7 +649,7 @@ def getWebURL(self, base=None):
649649
return self._getWebURL(base=base)
650650

651651

652-
class Playable(object):
652+
class Playable:
653653
""" This is a general place to store functions specific to media that is Playable.
654654
Things were getting mixed up a bit when dealing with Shows, Season, Artists,
655655
Albums which are all not playable.

plexapi/mixins.py

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
from plexapi.utils import deprecated
99

1010

11-
class AdvancedSettingsMixin(object):
11+
class AdvancedSettingsMixin:
1212
""" Mixin for Plex objects that can have advanced settings. """
1313

1414
def preferences(self):
@@ -60,7 +60,7 @@ def defaultAdvanced(self):
6060
self._server.query(url, method=self._server._session.put)
6161

6262

63-
class SmartFilterMixin(object):
63+
class SmartFilterMixin:
6464
""" Mixing for Plex objects that can have smart filters. """
6565

6666
def _parseFilters(self, content):
@@ -120,7 +120,7 @@ def _formatFilterGroups(self, groups):
120120
return {filterOp: rules}
121121

122122

123-
class SplitMergeMixin(object):
123+
class SplitMergeMixin:
124124
""" Mixin for Plex objects that can be split and merged. """
125125

126126
def split(self):
@@ -141,7 +141,7 @@ def merge(self, ratingKeys):
141141
return self._server.query(key, method=self._server._session.put)
142142

143143

144-
class UnmatchMatchMixin(object):
144+
class UnmatchMatchMixin:
145145
""" Mixin for Plex objects that can be unmatched and matched. """
146146

147147
def unmatch(self):
@@ -234,7 +234,7 @@ def fixMatch(self, searchResult=None, auto=False, agent=None):
234234
self._server.query(data, method=self._server._session.put)
235235

236236

237-
class ExtrasMixin(object):
237+
class ExtrasMixin:
238238
""" Mixin for Plex objects that can have extras. """
239239

240240
def extras(self):
@@ -244,7 +244,7 @@ def extras(self):
244244
return self.findItems(data, Extra, rtag='Extras')
245245

246246

247-
class HubsMixin(object):
247+
class HubsMixin:
248248
""" Mixin for Plex objects that can have related hubs. """
249249

250250
def hubs(self):
@@ -254,7 +254,7 @@ def hubs(self):
254254
return self.findItems(data, Hub, rtag='Related')
255255

256256

257-
class RatingMixin(object):
257+
class RatingMixin:
258258
""" Mixin for Plex objects that can have user star ratings. """
259259

260260
def rate(self, rating=None):
@@ -274,7 +274,7 @@ def rate(self, rating=None):
274274
self._server.query(key, method=self._server._session.put)
275275

276276

277-
class ArtUrlMixin(object):
277+
class ArtUrlMixin:
278278
""" Mixin for Plex objects that can have a background artwork url. """
279279

280280
@property
@@ -323,7 +323,7 @@ def unlockArt(self):
323323
return self._edit(**{'art.locked': 0})
324324

325325

326-
class BannerUrlMixin(object):
326+
class BannerUrlMixin:
327327
""" Mixin for Plex objects that can have a banner url. """
328328

329329
@property
@@ -372,7 +372,7 @@ def unlockBanner(self):
372372
return self._edit(**{'banner.locked': 0})
373373

374374

375-
class PosterUrlMixin(object):
375+
class PosterUrlMixin:
376376
""" Mixin for Plex objects that can have a poster url. """
377377

378378
@property
@@ -426,7 +426,7 @@ def unlockPoster(self):
426426
return self._edit(**{'thumb.locked': 0})
427427

428428

429-
class ThemeUrlMixin(object):
429+
class ThemeUrlMixin:
430430
""" Mixin for Plex objects that can have a theme url. """
431431

432432
@property
@@ -475,7 +475,7 @@ def unlockTheme(self):
475475
self._edit(**{'theme.locked': 0})
476476

477477

478-
class EditFieldMixin(object):
478+
class EditFieldMixin:
479479
""" Mixin for editing Plex object fields. """
480480

481481
def editField(self, field, value, locked=True, **kwargs):
@@ -667,7 +667,7 @@ def editCapturedTime(self, capturedTime, locked=True):
667667
return self.editField('originallyAvailableAt', capturedTime, locked=locked)
668668

669669

670-
class EditTagsMixin(object):
670+
class EditTagsMixin:
671671
""" Mixin for editing Plex object tags. """
672672

673673
@deprecated('use "editTags" instead')
@@ -986,7 +986,7 @@ def removeWriter(self, writers, locked=True):
986986
return self.editTags('writer', writers, locked=locked, remove=True)
987987

988988

989-
class WatchlistMixin(object):
989+
class WatchlistMixin:
990990
""" Mixin for Plex objects that can be added to a user's watchlist. """
991991

992992
def onWatchlist(self, account=None):

plexapi/myplex.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1333,7 +1333,7 @@ def syncItems(self):
13331333
return self._server.syncItems(client=self)
13341334

13351335

1336-
class MyPlexPinLogin(object):
1336+
class MyPlexPinLogin:
13371337
"""
13381338
MyPlex PIN login class which supports getting the four character PIN which the user must
13391339
enter on https://plex.tv/link to authenticate the client and provide an access token to

plexapi/sync.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ def _loadData(self, data):
130130
self.items.append(item)
131131

132132

133-
class Status(object):
133+
class Status:
134134
""" Represents a current status of specific :class:`~plexapi.sync.SyncItem`.
135135
136136
Attributes:
@@ -168,7 +168,7 @@ def __repr__(self):
168168
))
169169

170170

171-
class MediaSettings(object):
171+
class MediaSettings:
172172
""" Transcoding settings used for all media within :class:`~plexapi.sync.SyncItem`.
173173
174174
Attributes:
@@ -239,7 +239,7 @@ def createPhoto(resolution):
239239
raise BadRequest('Unexpected photo quality')
240240

241241

242-
class Policy(object):
242+
class Policy:
243243
""" Policy of syncing the media (how many items to sync and process watched media or not).
244244
245245
Attributes:

tools/plex-listdocattrs.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ def type_finder(s):
1616
return ''
1717

1818

19-
class AttDS(object):
19+
class AttDS:
2020
""" Helper that prints docstring attrs. """
2121

2222
def __init__(self, o, keys=None, style='google'):

0 commit comments

Comments
 (0)