create auth middleware
This commit is contained in:
@ -1,6 +1,9 @@
|
||||
import Elysia from "elysia";
|
||||
import { createUserRole } from "./controller/createUserRole.controller";
|
||||
import { unautenticatedMiddleware } from "../../middleware/auth/unauthenticated.middleware";
|
||||
|
||||
export const userRoleModule = new Elysia({ prefix: "/roles" })
|
||||
.get("/", () => "Hello User Role Module")
|
||||
.get("/", () => "Hello User Role Module", {
|
||||
beforeHandle: unautenticatedMiddleware,
|
||||
})
|
||||
.post("/", createUserRole);
|
||||
|
||||
Reference in New Issue
Block a user