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

Method GET

openlibrary/plugins/openlibrary/code.py:273–282  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

271 path = "/addbook"
272
273 def GET(self):
274 d = {"type": web.ctx.site.get("/type/edition")}
275
276 i = web.input()
277 author = i.get("author") and web.ctx.site.get(i.author)
278 if author:
279 d["authors"] = [author]
280
281 page = web.ctx.site.new("", d)
282 return render.edit(page, self.path, "Add Book")
283
284 def POST(self):
285 from infogami.core.code import edit

Callers

nothing calls this directly

Calls 2

getMethod · 0.45
newMethod · 0.45

Tested by

no test coverage detected