Skip to content

Commit

Permalink
Merge pull request #3 from vially/off-by-one
Browse files Browse the repository at this point in the history
Fix off-by-one error
  • Loading branch information
etcinit committed Nov 7, 2015
2 parents d8c8f34 + 82ef054 commit 663106c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion speedbump.go
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ func (r *RateLimiter) Attempt(id string) (bool, error) {
return false, err
}

if str != "" && intVal > r.max {
if str != "" && intVal >= r.max {
return false, nil
}

Expand Down

0 comments on commit 663106c

Please sign in to comment.