From 5111a139bcd467611577ac7bda6025a0b1f1381f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Elan=20Ruusam=C3=A4e?= Date: Mon, 24 Oct 2022 23:31:28 +0300 Subject: [PATCH] Fix super() call for python3 Use simplified super for python3: - https://docs.quantifiedcode.com/python-anti-patterns/correctness/bad_first_argument_given_to_super.html --- plextraktsync/commands/watch.py | 4 ++-- plextraktsync/plex_api.py | 2 +- plextraktsync/trakt_api.py | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/plextraktsync/commands/watch.py b/plextraktsync/commands/watch.py index d64fe08492..06352af1d1 100644 --- a/plextraktsync/commands/watch.py +++ b/plextraktsync/commands/watch.py @@ -16,7 +16,7 @@ class ScrobblerCollection(dict): def __init__(self, trakt: TraktApi, threshold=80): - super(dict, self).__init__() + super().__init__() self.trakt = trakt self.threshold = threshold @@ -27,7 +27,7 @@ def __missing__(self, key: Union[Movie, TVEpisode]): class SessionCollection(dict): def __init__(self, plex: PlexApi): - super(dict, self).__init__() + super().__init__() self.plex = plex def __missing__(self, key: str): diff --git a/plextraktsync/plex_api.py b/plextraktsync/plex_api.py index 3ce40c61fd..adce402c9a 100644 --- a/plextraktsync/plex_api.py +++ b/plextraktsync/plex_api.py @@ -93,7 +93,7 @@ def __str__(self): class PlexRatingCollection(dict): def __init__(self, plex: PlexApi): - super(dict, self).__init__() + super().__init__() self.plex = plex def __missing__(self, section_id: int): diff --git a/plextraktsync/trakt_api.py b/plextraktsync/trakt_api.py index d363cc9c0f..c1990cbd72 100644 --- a/plextraktsync/trakt_api.py +++ b/plextraktsync/trakt_api.py @@ -74,7 +74,7 @@ def _post(self, method: str, progress: float): class TraktRatingCollection(dict): def __init__(self, trakt: TraktApi): - super(dict, self).__init__() + super().__init__() self.trakt = trakt def __missing__(self, media_type: str):