MCPcopy Create free account
hub / github.com/internetarchive/openlibrary / POST

Method POST

openlibrary/plugins/admin/code.py:495–500  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

493 return render_template("admin/block", page)
494
495 def POST(self):
496 i = web.input()
497 ips = [ip.strip() for ip in i.ips.splitlines()]
498 self.block_ips(ips)
499 add_flash_message("info", "Saved!")
500 raise web.seeother("/admin/block")
501
502 def block_ips(self, ips):
503 page = web.ctx.get("/admin/block") or web.ctx.site.new("/admin/block", {"key": "/admin/block", "type": "/type/object"})

Callers

nothing calls this directly

Calls 1

block_ipsMethod · 0.95

Tested by

no test coverage detected