Urlopen try,except fixes

This commit is contained in:
Ruud
2011-11-11 15:47:57 +01:00
parent 0420bdeec5
commit 668b95353f
19 changed files with 116 additions and 133 deletions
+3 -3
View File
@@ -34,9 +34,9 @@ class FileManager(Plugin):
def download(self, url = '', dest = None, overwrite = False):
file = self.urlopen(url)
if not file:
log.error('File is empty, don\'t download')
try:
file = self.urlopen(url)
except:
return False
if not dest: # to Cache