Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Resumable uploads do not work with Safari nor ios #1394

Closed
jjchiw opened this issue Mar 1, 2016 · 3 comments
Closed

Resumable uploads do not work with Safari nor ios #1394

jjchiw opened this issue Mar 1, 2016 · 3 comments

Comments

@jjchiw
Copy link

jjchiw commented Mar 1, 2016

Hi!

I had an error with the flag resumeChunkSize trying to upload from safari and ios devices, the extra fields (_chunkSize, _currentChunkSize,_chunkNumber and _totalSize) didn't were added to the formData.

So I did a little debugging and read the code and I found this

this.isResumeSupported = function () {
    return window.Blob && (window.Blob instanceof Function) && window.Blob.prototype.slice;
  };

It seems that in Safari and in ios window.Blob is not an instance of Function so the flag resumeSupported was false.

I changed the code to:

this.isResumeSupported = function () {
    return window.Blob && (window.Blob instanceof Object) && window.Blob.prototype.slice;
  };

And its working, do you think it's an acceptable change? or do you think it has other consequences that I'm not seeing. I tested in Windows (Firefox, Chrome Edge) OSX (Safari, ios simulator safari, chrome)

@jjchiw jjchiw changed the title Resumable uploads do not worki with Safari nor ios Resumable uploads do not work with Safari nor ios Mar 1, 2016
@danialfarid
Copy link
Owner

It should be fine for the purpose of uploading but other Upload.xxx functions may not work properly specially like urlToBlob.

@danialfarid
Copy link
Owner

Fixed at 12.0.3

@jjchiw
Copy link
Author

jjchiw commented Mar 11, 2016

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants