mirror of
https://github.com/danbulant/discord.js
synced 2026-07-06 19:50:55 +00:00
Webpack build for branch master: 4be08406e6
This commit is contained in:
parent
63ba981165
commit
077de57ca3
2 changed files with 3 additions and 2 deletions
|
|
@ -960,6 +960,7 @@ module.exports = Collection;
|
||||||
|
|
||||||
/* WEBPACK VAR INJECTION */(function(Buffer) {const snekfetch = __webpack_require__(26);
|
/* WEBPACK VAR INJECTION */(function(Buffer) {const snekfetch = __webpack_require__(26);
|
||||||
const Constants = __webpack_require__(0);
|
const Constants = __webpack_require__(0);
|
||||||
|
const ConstantsHttp = Constants.DefaultOptions.http;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Contains various general-purpose utility methods. These functions are also available on the base `Discord` object.
|
* Contains various general-purpose utility methods. These functions are also available on the base `Discord` object.
|
||||||
|
|
@ -1014,7 +1015,7 @@ class Util {
|
||||||
static fetchRecommendedShards(token, guildsPerShard = 1000) {
|
static fetchRecommendedShards(token, guildsPerShard = 1000) {
|
||||||
return new Promise((resolve, reject) => {
|
return new Promise((resolve, reject) => {
|
||||||
if (!token) throw new Error('A token must be provided.');
|
if (!token) throw new Error('A token must be provided.');
|
||||||
snekfetch.get(Constants.Endpoints.gateway.bot)
|
snekfetch.get(`${ConstantsHttp.host}/api/v${ConstantsHttp.version}${Constants.Endpoints.gateway.bot}`)
|
||||||
.set('Authorization', `Bot ${token.replace(/^Bot\s*/i, '')}`)
|
.set('Authorization', `Bot ${token.replace(/^Bot\s*/i, '')}`)
|
||||||
.end((err, res) => {
|
.end((err, res) => {
|
||||||
if (err) reject(err);
|
if (err) reject(err);
|
||||||
|
|
|
||||||
2
discord.master.min.js
vendored
2
discord.master.min.js
vendored
File diff suppressed because one or more lines are too long
Loading…
Reference in a new issue