timotejroiko / discord.js-light

All the power of discord.js, zero caching. This library modifies discord.js's internal classes and functions in order to give you full control over its caching behaviour.
Apache License 2.0
292 stars 29 forks source link

Permission issues #20

Closed july12123 closed 4 years ago

july12123 commented 4 years ago

we were going to switch our bot to discord.js light but one issue stopped us. when looking for permissions on a channel for our bot the bitfield that returns is always 0.

july12123 commented 4 years ago

it just started working out of nowhere but keep this in mind.

timotejroiko commented 4 years ago

hey july, in order to check for permissions in channels there are some things you have to keep in mind: besides the channel in question, both guild roles and channel permissionOverwrites need to be available which, depending on your client options, may need to be fetched separately.

There are several ways to achieve this depending on the specific caches you have enabled in your client options, feel free to join my discord if you need any troubleshooting :)