forked from pothtonswer/discordmuffin
Use the everyone role to initialise the permission flags.
This commit is contained in:
parent
3cc6d4346d
commit
003454345b
1 changed files with 7 additions and 0 deletions
7
state.go
7
state.go
|
@ -706,6 +706,13 @@ func (s *State) UserChannelPermissions(userID, channelID string) (apermissions i
|
|||
return
|
||||
}
|
||||
|
||||
for _, role := range guild.Roles {
|
||||
if role.ID == guild.ID {
|
||||
apermissions |= role.Permissions
|
||||
break
|
||||
}
|
||||
}
|
||||
|
||||
for _, role := range guild.Roles {
|
||||
for _, roleID := range member.Roles {
|
||||
if role.ID == roleID {
|
||||
|
|
Loading…
Reference in a new issue