You've already forked node-redis
mirror of
https://github.com/redis/node-redis.git
synced 2025-08-09 00:22:08 +03:00
fix dirty selected DB check
This commit is contained in:
@@ -909,7 +909,7 @@ export default class RedisClient<
|
|||||||
*/
|
*/
|
||||||
resetIfDirty() {
|
resetIfDirty() {
|
||||||
let shouldReset = false;
|
let shouldReset = false;
|
||||||
if (this._self.#selectedDB !== this._self.#options?.database ?? 0) {
|
if (this._self.#selectedDB !== (this._self.#options?.database ?? 0)) {
|
||||||
console.warn('Returning a client with a different selected DB');
|
console.warn('Returning a client with a different selected DB');
|
||||||
shouldReset = true;
|
shouldReset = true;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user