Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/bwmarrin/discordgo
Browse files Browse the repository at this point in the history
  • Loading branch information
bwmarrin committed Oct 18, 2019
2 parents 8e3862b + e33a993 commit 8416350
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
4 changes: 2 additions & 2 deletions restapi.go
Original file line number Diff line number Diff line change
Expand Up @@ -617,10 +617,10 @@ func (s *Session) GuildCreate(name string) (st *Guild, err error) {
// g : A GuildParams struct with the values Name, Region and VerificationLevel defined.
func (s *Session) GuildEdit(guildID string, g GuildParams) (st *Guild, err error) {

// Bounds checking for VerificationLevel, interval: [0, 3]
// Bounds checking for VerificationLevel, interval: [0, 4]
if g.VerificationLevel != nil {
val := *g.VerificationLevel
if val < 0 || val > 3 {
if val < 0 || val > 4 {
err = ErrVerificationLevelBounds
return
}
Expand Down
5 changes: 3 additions & 2 deletions structs.go
Original file line number Diff line number Diff line change
Expand Up @@ -327,12 +327,13 @@ func (e *Emoji) APIName() string {
// VerificationLevel type definition
type VerificationLevel int

// Constants for VerificationLevel levels from 0 to 3 inclusive
// Constants for VerificationLevel levels from 0 to 4 inclusive
const (
VerificationLevelNone VerificationLevel = iota
VerificationLevelLow
VerificationLevelMedium
VerificationLevelHigh
VerificationLevelVeryHigh
)

// ExplicitContentFilterLevel type definition
Expand Down Expand Up @@ -1015,7 +1016,7 @@ const (
ErrCodeMissingAccess = 50001
ErrCodeInvalidAccountType = 50002
ErrCodeCannotExecuteActionOnDMChannel = 50003
ErrCodeEmbedCisabled = 50004
ErrCodeEmbedDisabled = 50004
ErrCodeCannotEditFromAnotherUser = 50005
ErrCodeCannotSendEmptyMessage = 50006
ErrCodeCannotSendMessagesToThisUser = 50007
Expand Down

0 comments on commit 8416350

Please sign in to comment.