refactor(WebSocketManager)!: remove deprecated rest option (#10998)

BREAKING CHANGE: The `rest` option in the `WebSocketManager` constructor has been removed. Pass a `fetchGatewayInformation` function instead.
This commit is contained in:
Almeida
2025-07-27 11:49:29 +01:00
committed by GitHub
parent 2e9bfba5f4
commit 08a61ca8e3
9 changed files with 98 additions and 281 deletions

View File

@@ -163,7 +163,7 @@ class Client extends BaseClient {
const wsOptions = {
...this.options.ws,
intents: this.options.intents.bitfield,
rest: this.rest,
fetchGatewayInformation: () => this.rest.get(Routes.gatewayBot()),
// Explicitly nulled to always be set using `setToken` in `login`
token: null,
};