diff --git a/lib/agent.js b/lib/agent.js index 702e39c9aae..320d7c473d8 100644 --- a/lib/agent.js +++ b/lib/agent.js @@ -110,9 +110,6 @@ class Agent extends DispatcherBase { async [kClose] () { const closePromises = [] for (const client of this[kClients].values()) { - if (client[kDeleteScheduled]) { - clearTimeout(client[kDeleteScheduled]) - } closePromises.push(client.close()) } this[kClients].clear() @@ -123,9 +120,6 @@ class Agent extends DispatcherBase { async [kDestroy] (err) { const destroyPromises = [] for (const client of this[kClients].values()) { - if (client[kDeleteScheduled]) { - clearTimeout(client[kDeleteScheduled]) - } destroyPromises.push(client.destroy(err)) } this[kClients].clear()