This commit is contained in:
Araq 2019-09-26 21:16:11 +02:00
commit 8dfb8727cd

View file

@ -61,10 +61,7 @@ proc uploadFile*(url: cstring, file: Blob, onprogress :proc(data: ProgressEvent)
ajax.setRequestHeader(a, b)
ajax.statechange proc() =
if this.readyState == 4:
if this.status == 200:
contWrapper(this.status, this.responseText)
else:
contWrapper(this.status, this.responseText)
contWrapper(this.status, this.responseText)
ajax.upload.onprogress = onprogress
ajax.send(formData.to(cstring))