Skip to content

Commit

Permalink
Reduced limit
Browse files Browse the repository at this point in the history
  • Loading branch information
manucorporat committed May 13, 2015
1 parent 313d05e commit d05b31e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion examples/realtime-advanced/limit.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ var ips = stats.New()
func ratelimit(c *gin.Context) {
ip := c.ClientIP()
value := ips.Add(ip, 1)
if value > 1000 {
if value > 400 {
c.AbortWithStatus(401)
}
}

0 comments on commit d05b31e

Please sign in to comment.