v5.0.0
版本发布时间: 2020-05-31 05:55:12
discordeno/discordeno最新发布版本:18.0.0(2023-01-13 07:50:21)
This version was heavily focused on improving cache/memory needs to be able to allow bigger bots using this library.
- Removed botID from client options. Instead, lib gets the botID from the READY event.
- fixed some payload typings where it was labelled as entire Member object instead of the proper Member Payload.
- All structures have had their methods removed and moved to separate handlers. This helped drop a lot of RAM usage. Instead of every single object having their own methods, now we just simply have 1 method available. This is crucial for allowing bots to grow bigger as once they have a lot of members this can start costing $$$.
- Some structures had quite a bit of redundant properties with snake case format. Those properties have been removed from the interface so they do not come up in VSC as you code anymore.
- Properly supports the new channel name/topic editing rate limiting.
Removed:
- updateChannelCache was an internal function but was exposed publically. This function has been removed entirely.
Added
- Collection class was added at request of users to make it easier to use methods on Maps.
- maxSize property on Collection can be used to prevent anything from caching. For example, if you don't care about caching members just set the members cache to maxSize = 0
- Cleaner logger exports so you can do
logger.error()
instead oflogRed()
- logger.success()
- logger.info()
- logger.error()
- logger.warn()
- Delete relevant cached messages when guild is deleted or when a channel is deleted.
- Message cache will sweep every minute deleting oldest messages in every channel only if that channel has more than 100 messages. Having too many messages allowed RAM to be taken up unlimited amount.
- Debug event handler to listen to logs from the library internal code.