summaryrefslogtreecommitdiffhomepage
path: root/libs/subliminal_patch/providers/supersubtitles.py
diff options
context:
space:
mode:
authorvitiko98 <[email protected]>2021-06-10 22:55:58 -0400
committervitiko98 <[email protected]>2021-06-10 22:55:58 -0400
commita39a9e8bd52542ff34a4a7b94a9504073e5aeabd (patch)
treeeb2b41f77642c6e66ea12469b7f5f8ab86d28f80 /libs/subliminal_patch/providers/supersubtitles.py
parente86d537ca2ffe49a6911b44d3c3611365461e232 (diff)
downloadbazarr-bad1b9f0618bf1d1c9da47ebeaea9c6dadcf8c5a.tar.gz
bazarr-bad1b9f0618bf1d1c9da47ebeaea9c6dadcf8c5a.zip
Finish providers migration to subliminal_patch's guess_matchesv0.9.6-beta.23
Diffstat (limited to 'libs/subliminal_patch/providers/supersubtitles.py')
-rw-r--r--libs/subliminal_patch/providers/supersubtitles.py9
1 files changed, 2 insertions, 7 deletions
diff --git a/libs/subliminal_patch/providers/supersubtitles.py b/libs/subliminal_patch/providers/supersubtitles.py
index bed39aa03..a859d9183 100644
--- a/libs/subliminal_patch/providers/supersubtitles.py
+++ b/libs/subliminal_patch/providers/supersubtitles.py
@@ -108,7 +108,8 @@ class SuperSubtitlesSubtitle(Subtitle):
return str(self.subtitle_id)
def get_matches(self, video):
- matches = guess_matches(video, guessit(self.release_info))
+ type_ = "movie" if isinstance(video, Movie) else "episode"
+ matches = guess_matches(video, guessit(self.release_info, {"type": type_}))
# episode
if isinstance(video, Episode):
@@ -150,12 +151,6 @@ class SuperSubtitlesSubtitle(Subtitle):
any(r in sanitize_release_group(self.version)
for r in get_equivalent_release_groups(sanitize_release_group(video.release_group)))):
matches.add('release_group')
- # resolution
- if video.resolution and self.version and video.resolution in self.version.lower():
- matches.add('resolution')
- # source
- if video.source and self.version and video.source.lower() in self.version.lower():
- matches.add('source')
self.matches = matches
return matches