Skip to content

Commit

Permalink
no more println
Browse files Browse the repository at this point in the history
  • Loading branch information
Zwiterrion committed Jan 9, 2025
1 parent f1f0223 commit c65466c
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions otoroshi/app/next/proxy/engine.scala
Original file line number Diff line number Diff line change
Expand Up @@ -2019,14 +2019,11 @@ class ProxyEngine() extends RequestHandler {
val (within, secCalls, maybeQuota) = r
// println(s"maybe quota - $maybeQuota")
val quota = maybeQuota.getOrElse(globalConfig.perIpThrottlingQuota)
println(s"[engine] secCalls $secCalls - perIpThrottlingQuota $quota")
// if (secCalls > (quota * 10L)) {
if (secCalls > quota) {
println("4")
errorResult(Results.TooManyRequests, "[IP] You performed too much requests", "errors.too.much.requests")
} else {
if (!within) {
println("3")
errorResult(Results.TooManyRequests, "[GLOBAL] You performed too much requests", "errors.too.much.requests")
} else if (globalConfig.ipFiltering.notMatchesWhitelist(remoteAddress)) {
errorResult(
Expand Down

0 comments on commit c65466c

Please sign in to comment.