1
0
Fork 0
Signed-off-by: Sam Therapy <sam@samtherapy.net>
This commit is contained in:
Sam Therapy 2024-03-23 17:37:25 +01:00
parent caa491736e
commit 69c250e5f2
Signed by: sam
GPG Key ID: 4D8B07C18F31ACBD
1 changed files with 2 additions and 1 deletions

View File

@ -28,9 +28,10 @@ app.get("/robots.txt", (c) => c.text("User-agent: *\nDisallow: /"))
app.all("/", (c) => {
const query: SearchQuery = {
site: c.req.query("booru") ?? "safebooru",
tags: c.req.query("tags") ??
tags: c.req.query("tags")?.split(",") ??
(c.req.header("Host") === "rint.osaka" ? "tohsaka_rin" : ""),
}
customLogger(`Tags: ${query.tags}`)
customLogger(`Host: ${c.req.header("Host")}`)
return Search(c, query)