small fix - add folder Downloads for attachmets
This commit is contained in:
parent
bdf6741016
commit
3382bd46c5
|
@ -448,6 +448,9 @@ class MyForm(QtGui.QMainWindow):
|
||||||
filename=self.attachArray[int(link)]['filename']
|
filename=self.attachArray[int(link)]['filename']
|
||||||
filename=filename.replace('"','')
|
filename=filename.replace('"','')
|
||||||
|
|
||||||
|
if(os.path.isdir('Downloads')==False):
|
||||||
|
os.mkdir('Downloads')
|
||||||
|
|
||||||
f = open("Downloads/"+filename, 'w')
|
f = open("Downloads/"+filename, 'w')
|
||||||
data=self.attachArray[int(link)]['content'].replace('\n','')
|
data=self.attachArray[int(link)]['content'].replace('\n','')
|
||||||
if(self.attachArray[int(link)]['encode'].find('base64')>-1):
|
if(self.attachArray[int(link)]['encode'].find('base64')>-1):
|
||||||
|
|
Reference in New Issue
Block a user