1
0
mirror of https://github.com/redis/node-redis.git synced 2025-08-06 02:15:48 +03:00

If there's an error in SELECT and there's no callback, emit the error.

This commit is contained in:
Bryan English
2014-02-18 22:02:33 -08:00
parent 2ff2a74ef6
commit 4672479b91
2 changed files with 12 additions and 0 deletions

View File

@@ -978,6 +978,8 @@ RedisClient.prototype.select = function (db, callback) {
}
if (typeof(callback) === 'function') {
callback(err, res);
} else if (err) {
self.emit('error', err);
}
});
};