summaryrefslogtreecommitdiffstats
path: root/fb.py
diff options
context:
space:
mode:
Diffstat (limited to 'fb.py')
-rwxr-xr-xfb.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/fb.py b/fb.py
index acfc3e6..7497ee2 100755
--- a/fb.py
+++ b/fb.py
@@ -99,7 +99,7 @@ class CURLWrapper:
def __add_post(self, data):
for item in data:
for key, value in item.items():
- self.post.append((key, (pycurl.FORM_CONTENTS, value)))
+ self.post.append((key, (pycurl.FORM_CONTENTS, value.encode('utf-8'))))
def getServerConfig(self):
if self.serverConfig is None:
@@ -151,7 +151,7 @@ class CURLWrapper:
for file in chunk:
counter+=1
self.post.append(
- ("file["+str(counter)+"]", (pycurl.FORM_FILE, file.path))
+ ("file["+str(counter)+"]", (pycurl.FORM_FILE, file.path.encode('utf-8')))
)
ret = self.send_post_progress("/file/upload", [])
rets["ids"] += ret["ids"]