Add middleware for verifying roles, use middleware on appropriate routs
This commit is contained in:
1 parent
465c1f9f9e
commit
5bd13a572e
5 files changed
+91
-10
No files matched your search
@@ -17,6 +17,9 @@ const errorMessages = {
|
||||
VERIFY_OWNER_NOT_FOUND: "Document not found",
|
||||
VERIFY_OWNER_UNAUTHORIZED: "Unauthorized access",
|
||||
|
||||
//Permissions Middleware
|
||||
INSUFFICIENT_PERMISSIONS: "Insufficient permissions",
|
||||
|
||||
//DB Errors
|
||||
DB_USER_EXISTS: "User already exists",
|
||||
DB_USER_NOT_FOUND: "User not found",
|
||||
|
||||
Reference in new issue
Block a user