mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-17 03:53:29 +01:00
misc: Remove Clyde (#2764)
* Remove Clyde * Remove Clyde avatar overwrite * Remove Clyde from the user pattern
This commit is contained in:
@@ -19,19 +19,6 @@ class ReadyHandler extends AbstractHandler {
|
|||||||
for (const guild of data.guilds) client.guilds.add(guild);
|
for (const guild of data.guilds) client.guilds.add(guild);
|
||||||
for (const privateDM of data.private_channels) client.channels.add(privateDM);
|
for (const privateDM of data.private_channels) client.channels.add(privateDM);
|
||||||
|
|
||||||
if (!client.users.has('1')) {
|
|
||||||
client.users.add({
|
|
||||||
id: '1',
|
|
||||||
username: 'Clyde',
|
|
||||||
discriminator: '0000',
|
|
||||||
avatar: 'https://discordapp.com/assets/f78426a064bc9dd24847519259bc42af.png',
|
|
||||||
bot: true,
|
|
||||||
status: 'online',
|
|
||||||
activity: null,
|
|
||||||
verified: true,
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
const t = client.setTimeout(() => {
|
const t = client.setTimeout(() => {
|
||||||
client.ws.connection.triggerReady();
|
client.ws.connection.triggerReady();
|
||||||
}, 1200 * data.guilds.length);
|
}, 1200 * data.guilds.length);
|
||||||
|
|||||||
@@ -160,7 +160,7 @@ MessageMentions.EVERYONE_PATTERN = /@(everyone|here)/g;
|
|||||||
* Regular expression that globally matches user mentions like `<@81440962496172032>`
|
* Regular expression that globally matches user mentions like `<@81440962496172032>`
|
||||||
* @type {RegExp}
|
* @type {RegExp}
|
||||||
*/
|
*/
|
||||||
MessageMentions.USERS_PATTERN = /<@!?(1|\d{17,19})>/g;
|
MessageMentions.USERS_PATTERN = /<@!?(\d{17,19})>/g;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Regular expression that globally matches role mentions like `<@&297577916114403338>`
|
* Regular expression that globally matches role mentions like `<@&297577916114403338>`
|
||||||
|
|||||||
@@ -124,7 +124,6 @@ exports.Endpoints = {
|
|||||||
Asset: name => `${root}/assets/${name}`,
|
Asset: name => `${root}/assets/${name}`,
|
||||||
DefaultAvatar: number => `${root}/embed/avatars/${number}.png`,
|
DefaultAvatar: number => `${root}/embed/avatars/${number}.png`,
|
||||||
Avatar: (userID, hash, format = 'default', size) => {
|
Avatar: (userID, hash, format = 'default', size) => {
|
||||||
if (userID === '1') return hash;
|
|
||||||
if (format === 'default') format = hash.startsWith('a_') ? 'gif' : 'webp';
|
if (format === 'default') format = hash.startsWith('a_') ? 'gif' : 'webp';
|
||||||
return makeImageUrl(`${root}/avatars/${userID}/${hash}`, { format, size });
|
return makeImageUrl(`${root}/avatars/${userID}/${hash}`, { format, size });
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user