File tree 1 file changed +10
-7
lines changed
1 file changed +10
-7
lines changed Original file line number Diff line number Diff line change @@ -48,8 +48,8 @@ export class RedisStore extends Store {
48
48
49
49
// Create a redis and ioredis compatible client
50
50
private normalizeClient ( client : any ) : NormalizedRedisClient {
51
- let isRedis = "scanIterator" in client || "masters" in client ;
52
- let isRedisCluster = "masters" in client ;
51
+ let isRedis = "scanIterator" in client || "masters" in client
52
+ let isRedisCluster = "masters" in client
53
53
54
54
return {
55
55
get : ( key ) => client . get ( key ) ,
@@ -67,15 +67,18 @@ export class RedisStore extends Store {
67
67
scanIterator : ( match , count ) => {
68
68
// node-redis createCluster impl.
69
69
if ( isRedisCluster ) {
70
- return ( async function * ( ) {
70
+ return ( async function * ( ) {
71
71
for ( const master of client . masters ) {
72
- const nodeClient = await client . nodeClient ( master ) ;
72
+ const nodeClient = await client . nodeClient ( master )
73
73
74
- for await ( const key of nodeClient . scanIterator ( { COUNT : count , MATCH : match } ) ) {
75
- yield key ;
74
+ for await ( const key of nodeClient . scanIterator ( {
75
+ COUNT : count ,
76
+ MATCH : match ,
77
+ } ) ) {
78
+ yield key
76
79
}
77
80
}
78
- } ) ( ) ;
81
+ } ) ( )
79
82
}
80
83
81
84
if ( isRedis ) return client . scanIterator ( { MATCH : match , COUNT : count } )
You can’t perform that action at this time.
0 commit comments