diff --git a/src/libs/getCurrentDomain.ts b/src/libs/getCurrentDomain.ts index 4e2af8c..d9bba18 100644 --- a/src/libs/getCurrentDomain.ts +++ b/src/libs/getCurrentDomain.ts @@ -1,5 +1,10 @@ import type { HonoRequest } from "hono"; export function getCurrentDomain(req: HonoRequest) { - return req.url.replace(req.path, ""); + let domain = req.url.replace(req.path, ""); + if (domain.includes("?")) { + domain = domain.split("?")[0]; + } + + return domain; }