From 94214fa73321f7fb73a149403dcb765cdad10372 Mon Sep 17 00:00:00 2001 From: Frangu Vlad Date: Sat, 18 Aug 2018 14:21:24 +0300 Subject: [PATCH] misc: Remove Clyde (#2764) * Remove Clyde * Remove Clyde avatar overwrite * Remove Clyde from the user pattern --- src/client/websocket/packets/handlers/Ready.js | 13 ------------- src/structures/MessageMentions.js | 2 +- src/util/Constants.js | 1 - 3 files changed, 1 insertion(+), 15 deletions(-) diff --git a/src/client/websocket/packets/handlers/Ready.js b/src/client/websocket/packets/handlers/Ready.js index c1a16df02..0e16400d1 100644 --- a/src/client/websocket/packets/handlers/Ready.js +++ b/src/client/websocket/packets/handlers/Ready.js @@ -19,19 +19,6 @@ class ReadyHandler extends AbstractHandler { for (const guild of data.guilds) client.guilds.add(guild); 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(() => { client.ws.connection.triggerReady(); }, 1200 * data.guilds.length); diff --git a/src/structures/MessageMentions.js b/src/structures/MessageMentions.js index 388da1c9f..bd99397d7 100644 --- a/src/structures/MessageMentions.js +++ b/src/structures/MessageMentions.js @@ -160,7 +160,7 @@ MessageMentions.EVERYONE_PATTERN = /@(everyone|here)/g; * Regular expression that globally matches user mentions like `<@81440962496172032>` * @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>` diff --git a/src/util/Constants.js b/src/util/Constants.js index ce5427552..80bc911ce 100644 --- a/src/util/Constants.js +++ b/src/util/Constants.js @@ -124,7 +124,6 @@ exports.Endpoints = { Asset: name => `${root}/assets/${name}`, DefaultAvatar: number => `${root}/embed/avatars/${number}.png`, Avatar: (userID, hash, format = 'default', size) => { - if (userID === '1') return hash; if (format === 'default') format = hash.startsWith('a_') ? 'gif' : 'webp'; return makeImageUrl(`${root}/avatars/${userID}/${hash}`, { format, size }); },