Skip to content

Commit

Permalink
Remove PlexGuidProvider prefix from class names
Browse files Browse the repository at this point in the history
  • Loading branch information
glensc committed Jan 1, 2025
1 parent 182df22 commit 29acd86
Show file tree
Hide file tree
Showing 7 changed files with 18 additions and 18 deletions.
24 changes: 12 additions & 12 deletions plextraktsync/plex/guid/provider/Factory.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@

from typing import TYPE_CHECKING

from .PlexGuidProviderIMDB import PlexGuidProviderIMDB
from .PlexGuidProviderLocal import PlexGuidProviderLocal
from .PlexGuidProviderMbid import PlexGuidProviderMbid
from .PlexGuidProviderTMDB import PlexGuidProviderTMDB
from .PlexGuidProviderTVDB import PlexGuidProviderTVDB
from .PlexGuidProviderYoutube import PlexGuidProviderYoutube
from .IMDB import IMDB
from .Local import Local
from .Mbid import Mbid
from .TMDB import TMDB
from .TVDB import TVDB
from .Youtube import Youtube

if TYPE_CHECKING:
from plextraktsync.plex.PlexGuid import PlexGuid
Expand All @@ -17,16 +17,16 @@ class Factory:
@classmethod
def create(cls, guid: PlexGuid):
if guid.provider == "imdb":
return PlexGuidProviderIMDB(guid)
return IMDB(guid)
if guid.provider == "tmdb":
return PlexGuidProviderTMDB(guid)
return TMDB(guid)
if guid.provider == "tvdb":
return PlexGuidProviderTVDB(guid)
return TVDB(guid)
if guid.provider == "mbid":
return PlexGuidProviderMbid(guid)
return Mbid(guid)
if guid.provider == "youtube":
return PlexGuidProviderYoutube(guid)
return Youtube(guid)
if guid.provider in ["local", "none"]:
return PlexGuidProviderLocal(guid)
return Local(guid)

raise RuntimeError(f"Unsupported provider: {guid.provider}")
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
from plextraktsync.plex.PlexGuid import PlexGuid


class PlexGuidProviderIMDB:
class IMDB:
def __init__(self, guid: PlexGuid):
self.guid = guid

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
from plextraktsync.plex.PlexGuid import PlexGuid


class PlexGuidProviderLocal:
class Local:
def __init__(self, guid: PlexGuid):
self.guid = guid

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
from plextraktsync.plex.PlexGuid import PlexGuid


class PlexGuidProviderMbid:
class Mbid:
def __init__(self, guid: PlexGuid):
self.guid = guid

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
from plextraktsync.plex.PlexGuid import PlexGuid


class PlexGuidProviderTMDB:
class TMDB:
url = "https://www.themoviedb.org"

def __init__(self, guid: PlexGuid):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
from plextraktsync.plex.PlexGuid import PlexGuid


class PlexGuidProviderTVDB:
class TVDB:
def __init__(self, guid: PlexGuid):
self.guid = guid

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
from plextraktsync.plex.PlexGuid import PlexGuid


class PlexGuidProviderYoutube:
class Youtube:
def __init__(self, guid: PlexGuid):
self.guid = guid

Expand Down

0 comments on commit 29acd86

Please sign in to comment.