mirror of
https://github.com/danbulant/discord.js
synced 2026-07-05 19:20:42 +00:00
Webpack build for branch master: f647eb7a91
This commit is contained in:
parent
75f8e17947
commit
9e1dface50
2 changed files with 6 additions and 3 deletions
|
|
@ -8841,6 +8841,7 @@ class ClientDataResolver {
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
* Resolves a ColorResolvable into a color number
|
||||||
* @param {ColorResolvable} color Color to resolve
|
* @param {ColorResolvable} color Color to resolve
|
||||||
* @returns {number} A color
|
* @returns {number} A color
|
||||||
*/
|
*/
|
||||||
|
|
@ -8850,11 +8851,13 @@ class ClientDataResolver {
|
||||||
} else if (color instanceof Array) {
|
} else if (color instanceof Array) {
|
||||||
color = (color[0] << 16) + (color[1] << 8) + color[2];
|
color = (color[0] << 16) + (color[1] << 8) + color[2];
|
||||||
}
|
}
|
||||||
|
|
||||||
if (color < 0 || color > 0xFFFFFF) {
|
if (color < 0 || color > 0xFFFFFF) {
|
||||||
throw new RangeError('Color must be within the range 0 - 16777215 (0xFFFFFF).');
|
throw new RangeError('Color must be within the range 0 - 16777215 (0xFFFFFF).');
|
||||||
} else if (color && isNaN(color)) {
|
} else if (color && isNaN(color)) {
|
||||||
throw new TypeError('Unable to convert color to a number.');
|
throw new TypeError('Unable to convert color to a number.');
|
||||||
}
|
}
|
||||||
|
|
||||||
return color;
|
return color;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -8863,7 +8866,7 @@ class ClientDataResolver {
|
||||||
* @returns {number} A color
|
* @returns {number} A color
|
||||||
*/
|
*/
|
||||||
resolveColor(color) {
|
resolveColor(color) {
|
||||||
return ClientDataResolver.resolveColor(color);
|
return this.constructor.resolveColor(color);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
4
discord.master.min.js
vendored
4
discord.master.min.js
vendored
File diff suppressed because one or more lines are too long
Loading…
Reference in a new issue