diff --git a/src/libs/FileSaver.js b/src/libs/FileSaver.js index 51a14bb8a..ad1d302d1 100644 --- a/src/libs/FileSaver.js +++ b/src/libs/FileSaver.js @@ -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");