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

Refactor js parser

Fix tests to work with Node.js 0.10
Improve average use case speed by up to 20%
Fix some small js parser issues
This commit is contained in:
Ruben Bridgewater
2015-11-23 11:17:05 +01:00
parent b6a81a4297
commit ac9ff9a3b1
4 changed files with 172 additions and 130 deletions

View File

@@ -294,14 +294,10 @@ RedisClient.prototype.init_parser = function () {
// Important: Only send results / errors async.
// That way the result / error won't stay in a try catch block and catch user things
this.reply_parser.send_error = function (data) {
process.nextTick(function() {
self.return_error(data);
});
self.return_error(data);
};
this.reply_parser.send_reply = function (data) {
process.nextTick(function() {
self.return_reply(data);
});
self.return_reply(data);
};
};