Skip to content

Commit

Permalink
Merge pull request #47 from jabetcha/master
Browse files Browse the repository at this point in the history
fixed upload error
  • Loading branch information
d0ugal authored Dec 30, 2018
2 parents b84c68e + 4244f42 commit 0d0f091
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion dropbox-upload/dropbox_upload/dropbox.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ def upload_file(dbx, file_path, dest_path):
f = open(file_path, "rb")
file_size = os.path.getsize(file_path)
if file_size <= CHUNK_SIZE:
return dbx.files_upload(f, dest_path)
return dbx.files_upload(f.read(), dest_path)

upload_session_start_result = dbx.files_upload_session_start(f.read(CHUNK_SIZE))
cursor = dropbox.files.UploadSessionCursor(
Expand Down

0 comments on commit 0d0f091

Please sign in to comment.