From 5c9f31f2442bedb5643b93412b366d10b062f525 Mon Sep 17 00:00:00 2001 From: Leibale Eidelman Date: Wed, 11 May 2022 09:35:36 -0400 Subject: [PATCH] fix #2123 - expose is ready (#2130) --- packages/client/lib/client/index.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/client/lib/client/index.ts b/packages/client/lib/client/index.ts index 836f7908416..fb86908bd2f 100644 --- a/packages/client/lib/client/index.ts +++ b/packages/client/lib/client/index.ts @@ -166,6 +166,10 @@ export default class RedisClient< return this.#socket.isOpen; } + get isReady(): boolean { + return this.#socket.isReady; + } + get v4(): Record { if (!this.#options?.legacyMode) { throw new Error('the client is not in "legacy mode"');