Only send PING to registered connections on focus

This commit is contained in:
Simon Ser 2025-02-28 17:43:13 +01:00
parent 76b6931ebb
commit fcc80a85e3

View File

@ -2006,7 +2006,9 @@ export default class App extends Component {
this.lastFocusPingDate = now; this.lastFocusPingDate = now;
for (let client of this.clients.values()) { for (let client of this.clients.values()) {
client.send({ command: "PING", params: ["gamja"] }); if (client.status === Client.Status.REGISTERED) {
client.send({ command: "PING", params: ["gamja"] });
}
} }
} }