Merge pull request #50 from seriousben/add_error_handler
Adding error handler on upload stream
This commit is contained in:
commit
1f69ece7c7
|
@ -114,6 +114,10 @@ exports.upload = function (provider, req, res, options, cb) {
|
||||||
}
|
}
|
||||||
var writer = provider.upload(uploadParams);
|
var writer = provider.upload(uploadParams);
|
||||||
|
|
||||||
|
writer.on('error', function(err) {
|
||||||
|
self._error(err);
|
||||||
|
});
|
||||||
|
|
||||||
var endFunc = function () {
|
var endFunc = function () {
|
||||||
self._flushing--;
|
self._flushing--;
|
||||||
var values = files[part.name];
|
var values = files[part.name];
|
||||||
|
|
Loading…
Reference in New Issue