Skip to content

Commit

Permalink
oppetarkiv: they changed the links for the videos.
Browse files Browse the repository at this point in the history
this fixes #238
  • Loading branch information
spaam committed Jun 28, 2015
1 parent 86d17b5 commit 5b015b9
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions lib/svtplay_dl/service/oppetarkiv.py
Expand Up @@ -16,9 +16,9 @@ def find_all_episodes(self, options):
if error:
log.error("Cant get web page")
return
match = re.search(r'"http://www.oppetarkiv.se/etikett/titel/([^"/]+)', data)
match = re.search(r'"/etikett/titel/([^"/]+)', data)
if match is None:
match = re.search(r'"http://www.oppetarkiv.se/etikett/titel/([^"/]+)', self.url)
match = re.search(r'"http://www.oppetarkiv.se/etikett/titel/([^/]+)/', self.url)
if match is None:
log.error("Couldn't find title")
return
Expand All @@ -38,11 +38,11 @@ def find_all_episodes(self, options):
visa = re.search(r'svtXColorDarkLightGrey', data)
if not visa:
more = False
regex = re.compile(r'(http://www.oppetarkiv.se/video/[^"]+)')
regex = re.compile(r'href="(/video/[^"]+)"')
for match in regex.finditer(data):
if n == options.all_last:
break
episodes.append(match.group(1))
episodes.append("http://www.oppetarkiv.se%s" % match.group(1))
n += 1
page += 1

Expand Down

0 comments on commit 5b015b9

Please sign in to comment.