Skip to content

Commit

Permalink
Add restart script on disconnect
Browse files Browse the repository at this point in the history
  • Loading branch information
ikuradon committed Nov 20, 2024
1 parent 82cea2a commit ff63dd7
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2137,6 +2137,11 @@ const main = async (): Promise<void> => {
process.exit(0);
});

relay.on("disconnect", () => {
console.error("切断されました…");
process.exit(0);
});

await relay.connect();
console.log("リレーに接続しました");

Expand Down

0 comments on commit ff63dd7

Please sign in to comment.