(handler)
| 513 | |
| 514 | |
| 515 | def block_ip_processor(handler): |
| 516 | if not web.ctx.path.startswith("/admin") and (web.ctx.method == "POST" or web.ctx.path.endswith("/edit")) and web.ctx.ip in get_blocked_ips(): |
| 517 | return render_template("permission_denied", web.ctx.path, "Your IP address is blocked.") |
| 518 | else: |
| 519 | return handler() |
| 520 | |
| 521 | |
| 522 | def daterange(startdate: datetime, *slice): |
nothing calls this directly
no test coverage detected