aboutsummaryrefslogtreecommitdiff
path: root/js/io
diff options
context:
space:
mode:
authorValerio Virgillito2012-08-22 10:34:23 -0700
committerValerio Virgillito2012-08-22 10:34:23 -0700
commiteb2ed31e6caafbf96c44b1a47a101ed55df29a77 (patch)
treeabe7d366106c66eb8d7af9e45175329d7790764b /js/io
parent8c8864bbbe8cde1f736785e1d3742841c332369b (diff)
parenta1d70077b5f1fafc965b4325283f29b08264c418 (diff)
downloadninja-eb2ed31e6caafbf96c44b1a47a101ed55df29a77.tar.gz
Merge pull request #433 from joseeight/Document
Fix: Removing version check for blob builder
Diffstat (limited to 'js/io')
-rw-r--r--js/io/system/chromeapi.js10
1 files changed, 3 insertions, 7 deletions
diff --git a/js/io/system/chromeapi.js b/js/io/system/chromeapi.js
index b13dd9de..ba0ed3f4 100644
--- a/js/io/system/chromeapi.js
+++ b/js/io/system/chromeapi.js
@@ -96,7 +96,7 @@ exports.ChromeApi = Montage.create(Object.prototype, {
96 // 96 //
97 f.createWriter(function(writer) { 97 f.createWriter(function(writer) {
98 // 98 //
99 var mime, blob, type = filePath.split('.'), version = parseInt(window.navigator.appVersion.match(/Chrome\/(\d+)\./)[1], 10); 99 var mime, blob, type = filePath.split('.'); //version = parseInt(window.navigator.appVersion.match(/Chrome\/(\d+)\./)[1], 10);
100 type = type[type.length-1]; 100 type = type[type.length-1];
101 switch (type) { 101 switch (type) {
102 case 'bmp': 102 case 'bmp':
@@ -136,12 +136,8 @@ exports.ChromeApi = Montage.create(Object.prototype, {
136 mime = 'text/'+type; 136 mime = 'text/'+type;
137 break; 137 break;
138 } 138 }
139 //TODO: Remove version checking once Chrome version 22 is stable 139 //
140 if (version > 21) { 140 blob = new Blob([new Uint8Array(content)], {type: type});
141 blob = new Blob([new Uint8Array(content)], {type: type});
142 } else {
143 blob = new Blob([content], {type: type});
144 }
145 // 141 //
146 writer.write(blob); 142 writer.write(blob);
147 // 143 //