Commit 1a6a0a32 authored by Tristan Cavelier's avatar Tristan Cavelier

splitstorage.js getAttachment no response fixed

parent d3d10cfe
......@@ -5,7 +5,7 @@
*/
/*jslint indent:2, maxlen: 80, nomen: true */
/*global jIO, define */
/*global jIO, define, Blob */
/**
* Provides a split storage for JIO. This storage splits data
......@@ -462,17 +462,15 @@
err,
response
) {
var i, doc;
if (err) {
err.message = "Unable to get attachment";
delete err.index;
return command.error(err);
}
doc = '';
for (i = 0; i < response.length; i += 1) {
doc += response[i].data;
}
that.success({"data": doc}); // XXX get mimetype
command.success({"data": new Blob(response.map(function (answer) {
return answer.data;
}), {"type": response[0].data.type})});
});
};
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment