Skip to content

Commit 4da34f3

Browse files
author
Peter Kuma
committed
Remove old commented-out code.
1 parent d97dbfb commit 4da34f3

File tree

2 files changed

+0
-12
lines changed

2 files changed

+0
-12
lines changed

fileshack/static/fileshack/js/models.js

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -214,9 +214,6 @@ var Item = new Class({
214214
body += '\r\n';
215215
body += window.btoa(chunk) + '\r\n';
216216
//body += chunk + '\r\n';
217-
//body += '--' + boundary + '\r\n';
218-
//body += 'Content-Disposition: form-data; name="csrfmiddlewaretoken"\r\n\r\n';
219-
//body += CSRF_TOKEN + '\r\n';
220217
body += '--' + boundary + '--\r\n';
221218

222219
this.xhr.setRequestHeader('Content-Type', 'multipart/form-data; boundary=' + boundary);

fileshack/views.py

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -178,15 +178,6 @@ def upload(request, store, id):
178178
try: id = int(id)
179179
except ValueError: raise Item.DoesNotExist
180180
item = Item.objects.get(pk=id)
181-
182-
#if item.status() != "UPLOADING" and item.status() != "STALE":
183-
# data = {
184-
# "status": "alreadyexists",
185-
# "error_label": "Upload failed",
186-
# "error_message": "An item with the exact content already exists",
187-
# "item": item.simple(),
188-
# }
189-
# return HttpResponseServerError(json.dumps(data, default=json_handler))
190181

191182
if item.fileobject.size < offset:
192183
time.sleep(0.5)

0 commit comments

Comments
 (0)