v2.0.0
This is a big update adding the Fetcher class & deprecating old functions.
const {Fetcher} = require('discord-fetch-messages');
// [...]
const fetcher = new Fetcher(client);
fetcher.on('fetchChannel', async channel => {
await message.channel.send(`Fetching <#${channel.id}>.`);
});
// [...]
await fetcher.fetchGuild(guildID); // Fetching a guild from ID.
await fetcher.fetchChannel(channel); // Fetching a channel.
Changelog
- Added Fetcher class. (8d136fa)
- Added TSDoc. (f72f382)
- Deprecated old
fetchGuildMessages
&fetchChannelMessages
functions. (e57218f) - Improved old functions code. (e71e2e3)
- Remade the
.gitignore
(193f2bb) - Removed
types
directory to git. (86472a0)