mirror of
https://github.com/lingble/safe-redis-leader.git
synced 2025-10-29 19:52:33 +00:00
clear timeouts before calling stop
This commit is contained in:
@@ -89,9 +89,9 @@ async function createSafeRedisLeader({
|
|||||||
}
|
}
|
||||||
|
|
||||||
async function shutdown(){
|
async function shutdown(){
|
||||||
await stop()
|
|
||||||
renewTimeoutId && clearTimeout(renewTimeoutId)
|
renewTimeoutId && clearTimeout(renewTimeoutId)
|
||||||
electTimeoutId && clearTimeout(electTimeoutId)
|
electTimeoutId && clearTimeout(electTimeoutId)
|
||||||
|
await stop()
|
||||||
}
|
}
|
||||||
|
|
||||||
return {
|
return {
|
||||||
|
|||||||
Reference in New Issue
Block a user