Skip to content

Commit 3d39ff2

Browse files
author
Paul Grove
committed
Bind this to promises
1 parent 1cc0b7c commit 3d39ff2

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

index.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,7 @@ RapidMango.prototype.download = function download() {
221221
});
222222
});
223223
});
224-
});
224+
}).bind(this);
225225
};
226226

227227
function RapidMango(options) {
@@ -273,7 +273,7 @@ RapidMango.prototype.install = function install() {
273273
return fs.unlinkAsync(archiveFilename);
274274
});
275275
});
276-
});
276+
}).bind(this);
277277
};
278278

279279
RapidMango.prototype.start = function start() {
@@ -341,7 +341,7 @@ RapidMango.prototype.start = function start() {
341341
});
342342
});
343343
return promise;
344-
});
344+
}).bind(this);
345345
};
346346

347347
RapidMango.prototype.stop = function stop() {
@@ -354,7 +354,7 @@ RapidMango.prototype.stop = function stop() {
354354
reject(err);
355355
});
356356
self.child.kill();
357-
})
358-
}
357+
}).bind(this);
358+
};
359359

360360
module.exports = RapidMango;

0 commit comments

Comments
 (0)