aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormax99x <max99x@gmail.com>2011-09-07 22:52:47 +0300
committermax99x <max99x@gmail.com>2011-09-07 22:52:47 +0300
commit44e2e9a57db053fb8a0bc0b4f62965d39fbb526c (patch)
treec590b9727a69f70e63fa3ad2d0cd79b1c6147959
parentfeee402bb4b97a94c4821d1eb69cd24c265ef04e (diff)
Made sure XHRs request typed arrays only if they can handle them.
-rw-r--r--src/library.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/library.js b/src/library.js
index 9cb1967a..f4829344 100644
--- a/src/library.js
+++ b/src/library.js
@@ -255,7 +255,7 @@ LibraryManager.library = {
xhr.open('GET', obj.url, false);
// Some hints to the browser that we want binary data.
- xhr.responseType = 'arraybuffer';
+ if (typeof Uint8Array != 'undefined') xhr.responseType = 'arraybuffer';
if (xhr.overrideMimeType) {
xhr.overrideMimeType('text/plain; charset=x-user-defined');
}