fix: revert member fetching in automod due to 429s
This commit is contained in:
parent
f00a7afab8
commit
d27f6f94df
1 changed files with 2 additions and 2 deletions
|
@ -13,8 +13,8 @@ export async function runAutomodOnMessage(
|
||||||
message: SavedMessage,
|
message: SavedMessage,
|
||||||
isEdit: boolean,
|
isEdit: boolean,
|
||||||
) {
|
) {
|
||||||
const member = await pluginData.guild.members.fetch(message.user_id).catch(() => undefined);
|
const member = pluginData.guild.members.resolve(message.user_id) ?? undefined;
|
||||||
const user = await pluginData.client.users.fetch(message.user_id).catch(() => undefined);
|
const user = pluginData.client.users.resolve(message.user_id) ?? undefined;
|
||||||
|
|
||||||
const context: AutomodContext = {
|
const context: AutomodContext = {
|
||||||
timestamp: moment.utc(message.posted_at).valueOf(),
|
timestamp: moment.utc(message.posted_at).valueOf(),
|
||||||
|
|
Loading…
Add table
Reference in a new issue