mirror of
https://github.com/spacebarchat/server.git
synced 2026-03-30 20:25:40 +00:00
Gateway: dont block on clearing voice states
Some checks failed
Build docker images / build (api) (push) Failing after 1m9s
Build docker images / build (cdn) (push) Failing after 1m20s
Build docker images / build (admin-api) (push) Failing after 4m7s
Build docker images / build (cdn-cs) (push) Failing after 1m50s
Build docker images / build (gateway) (push) Failing after 1m28s
Build / build (24.x) (push) Successful in 2m42s
Nix build / build-nix (push) Failing after 5m17s
Build docker images / build (gateway-offload) (push) Failing after 1m20s
Build docker images / build (default) (push) Failing after 5m30s
Style / build (24.x) (push) Failing after 2m18s
Some checks failed
Build docker images / build (api) (push) Failing after 1m9s
Build docker images / build (cdn) (push) Failing after 1m20s
Build docker images / build (admin-api) (push) Failing after 4m7s
Build docker images / build (cdn-cs) (push) Failing after 1m50s
Build docker images / build (gateway) (push) Failing after 1m28s
Build / build (24.x) (push) Successful in 2m42s
Nix build / build-nix (push) Failing after 5m17s
Build docker images / build (gateway-offload) (push) Failing after 1m20s
Build docker images / build (default) (push) Failing after 5m30s
Style / build (24.x) (push) Failing after 2m18s
This commit is contained in:
@@ -171,12 +171,9 @@ export class Server {
|
||||
await Config.init();
|
||||
await initEvent();
|
||||
// temporary fix
|
||||
console.log("[Gateway] Clearing voice states");
|
||||
await cleanupOnStartup();
|
||||
|
||||
console.log("[Gateway] dbg checking if server is listening");
|
||||
if (!this.server.listening) {
|
||||
console.log("gonna start listening on", this.port);
|
||||
this.server.listen(this.port);
|
||||
console.log(`[Gateway] online on 0.0.0.0:${this.port}`);
|
||||
}
|
||||
|
||||
@@ -53,9 +53,8 @@ export async function cleanupOnStartup(): Promise<void> {
|
||||
// },
|
||||
//);
|
||||
|
||||
try {
|
||||
await VoiceState.clear();
|
||||
} catch (e) {
|
||||
console.error("Error clearing voice states on startup:", e);
|
||||
}
|
||||
console.log("[Gateway] Starting async voice state wipe...");
|
||||
VoiceState.clear()
|
||||
.then((e) => console.log("[Gateway] Successfully cleaned voice states"))
|
||||
.catch((e) => console.error("[Gateway] Error cleaning voice states on startup:", e));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user