aiko-chan-ai / discord.js-selfbot-v13

An unofficial discord.js fork for creating selfbots
https://discordjs-self-v13.netlify.app
GNU General Public License v3.0
751 stars 160 forks source link

Fetch a deleted message #723

Closed Unknown-user-dev closed 1 year ago

Unknown-user-dev commented 1 year ago

Which package has the bugs?

The core library

Issue description

1 : Type !snipe 2 : Get the channel 3 : get the deleted message 4 : send the deleted message

But, i search how to get a deleted message/image

Code sample

No response

Package version

2.10.1

Node.js version

16.13.0

Operating system

Windows

Priority this issue should have

Low (slightly annoying)

Checklist

Additional Information

No response

aiko-chan-ai commented 1 year ago

cache ?

Unknown-user-dev commented 1 year ago

discordjs-selfbot-v13 dont have a client.on("......") for deleted message ?

aiko-chan-ai commented 1 year ago

messageDelete ?

Unknown-user-dev commented 1 year ago

i will try wait

Unknown-user-dev commented 1 year ago

like that ?

client.on("messageDelete", async message => { if (config.antidelete === false) return const channel = client.channels.cache.get(message.channel.id) const user = message.author const content = message.content

message.channel.send(`${user}, ${content}`)

})

aiko-chan-ai commented 1 year ago

check message.partial first

Unknown-user-dev commented 1 year ago

like : if (message.partial) await message.fetch();

aiko-chan-ai commented 1 year ago

you cannot fetch a deleted message

Unknown-user-dev commented 1 year ago

like i want to do a message sniper, idk if u know, but i know a bot, when u do +snipe on a deleted message the bot will reply the deleted message

aiko-chan-ai commented 1 year ago

that's when the message is still cached

Unknown-user-dev commented 1 year ago

okay thanks !