refactor: create getCurrentDomain helper function
This commit is contained in:
5
src/libs/getCurrentDomain.ts
Normal file
5
src/libs/getCurrentDomain.ts
Normal file
@@ -0,0 +1,5 @@
|
||||
import type { HonoRequest } from "hono";
|
||||
|
||||
export function getCurrentDomain(req: HonoRequest) {
|
||||
return req.url.replace(req.path, "");
|
||||
}
|
||||
Reference in New Issue
Block a user