adding TODO comments

This commit is contained in:
jake 2025-06-07 09:31:00 -04:00
parent b8bfb76b83
commit 9ffab89ebf
Signed by: jake
GPG Key ID: 9C14443265672660

View File

@ -67,6 +67,7 @@ func New(opts ...Option) Bolt {
//set default command indicator
b.indicator = "."
//apply options to bolt
for _, o := range opts {
o(b)
}
@ -85,6 +86,7 @@ func (b *bolt) Start() error {
return err
}
//safe shutdown handler
sigChannel := make(chan os.Signal, 1)
signal.Notify(sigChannel, syscall.SIGINT)
<-sigChannel
@ -241,7 +243,8 @@ func (b *bolt) getRemainingTimeout(timeout time.Time) string {
// checks if the author of msg has the correct role to run the requested command
func (b *bolt) roleCheck(msg *dg.MessageCreate, s *dg.Session, run Command) (bool, error) {
var found bool
//loop thru author roles
//loop thru author roles, there may be a better way to check for this UNION
//TODO: improve role search performance to support bigger lists
for _, r := range msg.Member.Roles {
//get role name from ID
n, err := s.State.Role(msg.GuildID, r)