Skip to content

Commit

Permalink
fix(FileSaver): HTMLAnchorElement is not defined (#3073)
Browse files Browse the repository at this point in the history
  • Loading branch information
OmedMilat authored Jan 25, 2021
1 parent 63f89d4 commit ef70f92
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/libs/FileSaver.js
Original file line number Diff line number Diff line change
Expand Up @@ -89,8 +89,8 @@ var saveAs =
? function saveAs() {
/* noop */
}
: // Use download attribute first if possible (#193 Lumia mobile)
"download" in HTMLAnchorElement.prototype
: // Use download attribute first if possible (#193 Lumia mobile) unless this is a native app
(typeof HTMLAnchorElement !== "undefined" && "download" in HTMLAnchorElement.prototype)
? function saveAs(blob, name, opts) {
var URL = _global.URL || _global.webkitURL;
var a = document.createElement("a");
Expand Down

0 comments on commit ef70f92

Please sign in to comment.