Skip to content

Commit bc31d5b

Browse files
committed
chore: cleanup
1 parent 62ce3e0 commit bc31d5b

File tree

1 file changed

+1
-9
lines changed

1 file changed

+1
-9
lines changed

packages/serverless/src/backend_connector.js

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -218,15 +218,7 @@ function scheduleLambdaExtensionHeartbeatRequest(heartbeatOpts = {}) {
218218
// Make sure we do not try to talk to the Lambda extension again.
219219
options.useLambdaExtension = false;
220220
clearInterval(heartbeatInterval);
221-
222-
// Destroy timed out request manually as mandated in https://nodejs.org/api/http.html#event-timeout.
223-
if (req && !req.destroyed) {
224-
try {
225-
destroyRequest(req);
226-
} catch (e) {
227-
// ignore
228-
}
229-
}
221+
destroyRequest(req);
230222
});
231223

232224
req.end();

0 commit comments

Comments
 (0)