diff options
Diffstat (limited to 'module/plugins/hoster/YourfilesTo.py')
-rw-r--r-- | module/plugins/hoster/YourfilesTo.py | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/module/plugins/hoster/YourfilesTo.py b/module/plugins/hoster/YourfilesTo.py index 2c3656c95..f2f44d41b 100644 --- a/module/plugins/hoster/YourfilesTo.py +++ b/module/plugins/hoster/YourfilesTo.py @@ -55,9 +55,13 @@ class YourfilesTo(Hoster): def get_file_url(self):
""" returns the absolute downloadable filepath
"""
- url = re.search(r"var bla = '(.*?)';", self.html).group(1)
- url = urllib.unquote(url.replace("http://http:/http://", "http://").replace("dumdidum", ""))
- return url
+ url = re.search(r"var bla = '(.*?)';", self.html)
+ if url:
+ url = url.group(1)
+ url = urllib.unquote(url.replace("http://http:/http://", "http://").replace("dumdidum", ""))
+ return url
+ else:
+ self.fail("absolute filepath could not be found. offline? ")
def get_file_name(self):
if self.html is None:
|