mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-11 17:13:31 +01:00
chore(deps): update deps and fix lint (#3833)
This commit is contained in:
@@ -36,7 +36,7 @@ class SnowflakeUtil {
|
||||
if (timestamp instanceof Date) timestamp = timestamp.getTime();
|
||||
if (typeof timestamp !== 'number' || isNaN(timestamp)) {
|
||||
throw new TypeError(
|
||||
`"timestamp" argument must be a number (received ${isNaN(timestamp) ? 'NaN' : typeof timestamp})`
|
||||
`"timestamp" argument must be a number (received ${isNaN(timestamp) ? 'NaN' : typeof timestamp})`,
|
||||
);
|
||||
}
|
||||
if (INCREMENT >= 4095) INCREMENT = 0;
|
||||
|
||||
@@ -45,7 +45,7 @@ class Structures {
|
||||
if (typeof extender !== 'function') {
|
||||
const received = `(received ${typeof extender})`;
|
||||
throw new TypeError(
|
||||
`"extender" argument must be a function that returns the extended structure class/prototype ${received}.`
|
||||
`"extender" argument must be a function that returns the extended structure class/prototype ${received}.`,
|
||||
);
|
||||
}
|
||||
|
||||
@@ -60,7 +60,7 @@ class Structures {
|
||||
const received = `${extended.name || 'unnamed'}${prototype.name ? ` extends ${prototype.name}` : ''}`;
|
||||
throw new Error(
|
||||
'The class/prototype returned from the extender function must extend the existing structure class/prototype' +
|
||||
` (received function ${received}; expected extension of ${structures[structure].name}).`
|
||||
` (received function ${received}; expected extension of ${structures[structure].name}).`,
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -437,7 +437,7 @@ class Util {
|
||||
return collection.sorted((a, b) =>
|
||||
a.rawPosition - b.rawPosition ||
|
||||
parseInt(b.id.slice(0, -10)) - parseInt(a.id.slice(0, -10)) ||
|
||||
parseInt(b.id.slice(10)) - parseInt(a.id.slice(10))
|
||||
parseInt(b.id.slice(10)) - parseInt(a.id.slice(10)),
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user