Fix the callback

This commit is contained in:
Raymond Feng 2015-05-27 13:40:03 -07:00
parent 455774e666
commit 39cb95579a
1 changed files with 3 additions and 2 deletions

View File

@ -405,11 +405,12 @@ SQLConnector.prototype.execute = function(sql, params, options, callback) {
options: options options: options
}; };
this.notifyObserversAround('execute', context, function(context, done) { this.notifyObserversAround('execute', context, function(context, done) {
self.executeSQL(sql, params, options, function(err, info, extra) { self.executeSQL(sql, params, options, function(err, info) {
if (!err && info != null) { if (!err && info != null) {
context.res = info; context.res = info;
} }
done(err, info, extra); // Don't pass more than one args as it will confuse async.waterfall
done(err, info);
}); });
}, callback); }, callback);
}; };