Skip to content

Commit

Permalink
Fix #1433
Browse files Browse the repository at this point in the history
  • Loading branch information
mnapoli committed Feb 27, 2023
1 parent 1ca2f3d commit d8af991
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,6 @@ class ServerlessPlugin {
this.telemetry();
} catch (e) {
// These errors should not stop the execution
this.logVerbose(`Could not send telemetry: ${e}`);
}
},
// Custom commands
Expand Down Expand Up @@ -244,9 +243,13 @@ class ServerlessPlugin {
// or execution time.
client.send(JSON.stringify(payload), 8888, '108.128.197.71', (err) => {
if (err) {
this.logVerbose(`Could not send telemetry: ${err.message}`);
// These errors should not stop the execution
}
try {
client.close();
} catch (e) {
// These errors should not stop the execution
}
client.close();
});
}
}
Expand Down

0 comments on commit d8af991

Please sign in to comment.