Fix tests

One can use transforms with Browserify, so I added babelify in order to
compile all node modules to ES5.
This commit is contained in:
2017-02-17 21:30:53 +08:00
parent 0bf09fbe49
commit fe356429fe
3 changed files with 13 additions and 2 deletions
+2 -2
View File
@@ -17,13 +17,13 @@ export default Ember.Service.extend({
storeFile(content) {
let ipfs = this.get('ipfs');
return ipfs.add(new ipfs.Buffer(content)).then((res) => {
return ipfs.add(new ipfs.Buffer(content)).then(res => {
return res[0].hash;
});
},
getFile(hash) {
return this.get('ipfs').cat(hash, { buffer: true }).then(res) => {
return this.get('ipfs').cat(hash, { buffer: true }).then(res => {
return res.toString();
});
}