We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 6865aba + ac59621 commit d57305bCopy full SHA for d57305b
redisinsight/api/src/modules/core/services/redis/redis.service.ts
@@ -1,6 +1,7 @@
1
import { Injectable, Logger } from '@nestjs/common';
2
import { ConnectionOptions, SecureContextOptions } from 'tls';
3
import * as Redis from 'ioredis';
4
+import { isEmpty } from 'lodash';
5
import IORedis, { RedisOptions } from 'ioredis';
6
import { v4 as uuidv4 } from 'uuid';
7
import {
@@ -120,7 +121,7 @@ export class RedisService {
120
121
});
122
cluster.on('error', (e): void => {
123
this.logger.error('Failed connection to the redis oss cluster', e);
- reject(e);
124
+ reject(!isEmpty(e.lastNodeError) ? e.lastNodeError : e);
125
126
cluster.on('ready', (): void => {
127
this.logger.log('Successfully connected to the redis oss cluster.');
0 commit comments