mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-11 09:03:29 +01:00
Move protocol version to a constant, and reorganise constants a bit
This commit is contained in:
@@ -40,7 +40,7 @@ class RESTMethods {
|
||||
return new Promise((resolve, reject) => {
|
||||
this.rest.makeRequest('get', Constants.Endpoints.gateway, true)
|
||||
.then(res => {
|
||||
this.rest.client.ws.gateway = `${res.url}/?encoding=json&v=${this.rest.client.options.protocolVersion}`;
|
||||
this.rest.client.ws.gateway = `${res.url}/?encoding=json&v=${Constants.PROTOCOL_VERSION}`;
|
||||
resolve(this.rest.client.ws.gateway);
|
||||
})
|
||||
.catch(reject);
|
||||
|
||||
Reference in New Issue
Block a user