You've already forked node-redis
mirror of
https://github.com/redis/node-redis.git
synced 2025-08-04 15:02:09 +03:00
chore: refactor flush and error
This commit is contained in:
@@ -29,10 +29,7 @@ function createParser (client) {
|
||||
// Note: the execution order is important. First flush and emit, then create the stream
|
||||
err.message += '. Please report this.'
|
||||
client.ready = false
|
||||
client.flushAndError({
|
||||
message: 'Fatal error encountered. Command aborted.',
|
||||
code: 'NR_FATAL'
|
||||
}, {
|
||||
client.flushAndError('Fatal error encountered. Command aborted.', 'NR_FATAL', {
|
||||
error: err,
|
||||
queues: ['commandQueue']
|
||||
})
|
||||
|
Reference in New Issue
Block a user