Update types to fix discordgo updates
This commit is contained in:
parent
c38729441b
commit
0701c6f791
@ -37,7 +37,11 @@ func (s *StatusManager) SetInterval(interval string) {
|
|||||||
// UpdateStatus updates the status of the bot
|
// UpdateStatus updates the status of the bot
|
||||||
func (s *StatusManager) UpdateStatus(session *discordgo.Session) error {
|
func (s *StatusManager) UpdateStatus(session *discordgo.Session) error {
|
||||||
i := rand.Intn(len(s.Values))
|
i := rand.Intn(len(s.Values))
|
||||||
err := session.UpdateStatus(0, s.Values[i])
|
usd := discordgo.UpdateStatusData {
|
||||||
|
Status: s.Values[i],
|
||||||
|
AFK: false,
|
||||||
|
}
|
||||||
|
err := session.UpdateStatusComplex(usd)
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
2
types.go
2
types.go
@ -13,7 +13,7 @@ type CommandInvokeFunc func(Context, []string)
|
|||||||
type PrefixesFunc func(string) []string
|
type PrefixesFunc func(string) []string
|
||||||
|
|
||||||
// Permission type to help with managing permissions for commands
|
// Permission type to help with managing permissions for commands
|
||||||
type Permission int
|
type Permission int64
|
||||||
|
|
||||||
// Defining permissions based on the Discord API
|
// Defining permissions based on the Discord API
|
||||||
const (
|
const (
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user