From 05d01d2282a7cf1d78bd4525ee6e0637be4eec35 Mon Sep 17 00:00:00 2001 From: Manu Mtz-Almeida Date: Thu, 14 May 2015 22:52:37 +0200 Subject: [PATCH] Restored old limits --- examples/realtime-advanced/routes.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/examples/realtime-advanced/routes.go b/examples/realtime-advanced/routes.go index bc516fcd..4ac95aa0 100644 --- a/examples/realtime-advanced/routes.go +++ b/examples/realtime-advanced/routes.go @@ -14,11 +14,11 @@ func rateLimit(c *gin.Context) { ip := c.ClientIP() value := int(ips.Add(ip, 1)) - if value%10 == 0 { + if value%50 == 0 { fmt.Printf("ip: %s, count: %d\n", ip, value) } - if value >= 100 { - if value%100 == 0 { + if value >= 200 { + if value%200 == 0 { fmt.Println("ip blocked") } c.Abort()