Skip to content
This repository has been archived by the owner on Jul 19, 2024. It is now read-only.

v2.2.3 New Stuff

Compare
Choose a tag to compare
@iREDMe iREDMe released this 04 Nov 15:24
· 331 commits to master since this release
3286861

v2.2.3

This update includes a lot of changes.

These are the New Changes...in no particular order...

  • Now uses Node-Fetch instead of snekfetch

  • New (and changed) Classes!
    • PartialUser => This is used whenever a user is fetched from a bot/guild/bot's upvotes, since some values are missing due to circular references.
    • FetchError => A not-very-polished error class that is thrown when an error on the site is occurred.
    • Emoji => Used when fetching a Guild's emojis (also new)
    • PostOptions => Options when posting guild count.
    • UpvoteFetchOptions => Options when fetching for a bot's upvotes.
    • FetchOptions => Now includes .stringify parameter
      • If set to TRUE, returns the stringifed form of Bots/Users (mention), Guilds (name), or Emoji (text-that-transforms-into-a-readable-emoji-for-Discord)
    • NonGuildBase is now dead. Not big soup rice, as Heavy would say.

  • Functions Changed!
    • fetchAll() has now been split.
      • Use fetchAllBots() or fetchAllEmojis()
    • edit() now only returns the new ClientOptions that have been set.
    • fetchEmoji() => Fetch an emoji on the site!
    • fetchGuildEmojis() => Fetches all emojis that a guild has.
    • setGuilds() => Functionality Now Changed.
      • Now wants setGuilds({ guildSize: number | array of numbers })
      • You can now use: setGuilds({ token: 'API_TOKEN', botID: 'BOT_ID' }) so you don't have to supply them on initialization(?)
    • fetchUpvotes() no longer allows to get another bot's because I only figured out now in the past 2 days that you can't fetch other bots' upvotes LOL
      • fetchUpvotes() usage changed. Now use fetchUpvotes({ ids: true }) if you want only user IDs.

Usability?

  • I do not know if the setGuilds or the fetchUpvotes work, since my bot for testing purposes got died...