adding author id to message struct

This commit is contained in:
jake 2025-06-25 19:12:34 -04:00
parent dd20b73b76
commit 113fcbf2d1
Signed by: jake
GPG Key ID: 9C14443265672660
2 changed files with 2 additions and 0 deletions

View File

@ -193,6 +193,7 @@ func (b *bolt) handleCommand(msg *dg.MessageCreate, s *dg.Session, server *dg.Gu
//run command payload
res, err := run.Payload(Message{
Author: msg.Author.Username,
ID: msg.Author.ID,
Words: words,
Content: msg.Content,
Channel: channel.Name,

View File

@ -17,6 +17,7 @@ type Payload func(msg Message) (string, error)
// message information passed to payload function
type Message struct {
Author string //username of message author
ID string //discord ID of message author
Words []string //words from message split on whitespace
Content string //entire message content
Channel string //message channel