From 336d264e8445362cd41a5ecda375dad1400cd8df Mon Sep 17 00:00:00 2001 From: RaNaN Date: Mon, 28 May 2012 18:04:46 +0200 Subject: closed #587 --- module/plugins/hoster/RealdebridCom.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/module/plugins/hoster/RealdebridCom.py b/module/plugins/hoster/RealdebridCom.py index 4fc3b4306..ff4843afd 100644 --- a/module/plugins/hoster/RealdebridCom.py +++ b/module/plugins/hoster/RealdebridCom.py @@ -12,7 +12,7 @@ from module.plugins.Hoster import Hoster class RealdebridCom(Hoster): __name__ = "RealdebridCom" - __version__ = "0.48" + __version__ = "0.49" __type__ = "hoster" __pattern__ = r"https?://.*real-debrid\..*" @@ -25,7 +25,7 @@ class RealdebridCom(Hoster): name = unquote(url.rsplit("/", 1)[1]) except IndexError: name = "Unknown_Filename..." - if name.endswith(".."): #incomplete filename, append random stuff + if not name or name.endswith(".."): #incomplete filename, append random stuff name += "%s.tmp" % randrange(100,999) return name @@ -61,7 +61,7 @@ class RealdebridCom(Hoster): self.logWarning(data["message"]) self.tempOffline() else: - if self.pyfile.name and not self.pyfile.name.endswith('.tmp'): + if self.pyfile.name is not None and self.pyfile.name.endswith('.tmp') and data["file_name"]: self.pyfile.name = data["file_name"] self.pyfile.size = parseFileSize(data["file_size"]) new_url = data['generated_links'][0][-1] -- cgit v1.2.3