call back with errors instead of throwing within the Storage module
This commit is contained in:
@@ -15,7 +15,8 @@ const init = function (config, cb) {
|
||||
return void cb('E_INVALID_CONFIG');
|
||||
}
|
||||
|
||||
Store.create(config, function (_store) {
|
||||
Store.create(config, function (err, _store) {
|
||||
if (err) { return void cb(err); }
|
||||
store = _store;
|
||||
cb();
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user