-
-
Notifications
You must be signed in to change notification settings - Fork 37
Closed
Labels
semver-minorIssue or PR that should land as semver minorIssue or PR that should land as semver minor
Description
🐛 Bug Report
Hey 👋,I noticed if you provide a Redis
client in namespace there is no option for closing the client as you have in a non namespace instance.
To Reproduce
Steps to reproduce the behavior:
if (namespace) {
....
if (!client) {
....
fastify.addHook('onClose', closeNamedInstance)
}
fastify.redis[namespace] = client
}
Expected behavior
I would expect to have the same snippet as in non namespace
if (options.closeClient === true) {
fastify.addHook('onClose', closeNamedInstance)
}
Sorry If I understood it wrong but this is what I would expect. If that's the case though seems a quick fix and I could create a pr for it.
Metadata
Metadata
Assignees
Labels
semver-minorIssue or PR that should land as semver minorIssue or PR that should land as semver minor