Skip to content

Conversation

@dplewis
Copy link
Member

@dplewis dplewis commented Mar 27, 2019

http and https modules don't exist in browser

@dplewis dplewis requested a review from acinader March 28, 2019 00:24
@codecov
Copy link

codecov bot commented Mar 28, 2019

Codecov Report

Merging #765 into master will increase coverage by 0.03%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #765      +/-   ##
==========================================
+ Coverage   90.33%   90.37%   +0.03%     
==========================================
  Files          54       54              
  Lines        4886     4905      +19     
  Branches     1084     1089       +5     
==========================================
+ Hits         4414     4433      +19     
  Misses        472      472
Impacted Files Coverage Δ
src/ParseFile.js 97.33% <100%> (+0.38%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 45658b9...2ad91da. Read the comment docs.

Copy link
Contributor

@acinader acinader left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i'm confused...

src/ParseFile.js Outdated
if (XHR) {
return this.downloadAjax(uri);
}
if (process.env.PARSE_BUILD !== 'node') {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe i don't understand what process.env.PARSE_BUILD is, but the way I'm reading this is:

if we're not in node, complain that we don't have XMLHttpRequest, but XMLHttpRequest is in the browser, not node. set me straight here :).

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For browsers that don't support ajax.

https://www.tutorialspoint.com/ajax/ajax_browser_support.htm

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@dplewis dplewis requested a review from acinader March 28, 2019 04:05
@dplewis dplewis merged commit fe05d70 into master Mar 28, 2019
@dplewis dplewis deleted the file-uri-browser branch March 28, 2019 04:05
@dplewis dplewis changed the title (Browser) Support for File Uri Upload (Browser / React-Native) Support for File Uri Upload Mar 28, 2019
dplewis added a commit that referenced this pull request Mar 28, 2019
dplewis pushed a commit that referenced this pull request Mar 28, 2019
* Changelog for patch release 2.3.1

* Update CHANGELOG.md

* Changelog for patch release 2.3.1

* add more

* Update CHANGELOG.md

* Add #765
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants