chore: Use currentUser from authentication
This commit is contained in:
@@ -1,10 +1,6 @@
|
||||
import { Request, Response, NextFunction } from 'express';
|
||||
import User from '../models/user';
|
||||
import UserType from '../types/user';
|
||||
|
||||
interface RequestWithCurrentUser extends Request {
|
||||
currentUser: UserType
|
||||
}
|
||||
import RequestWithCurrentUser from '../types/express/request-with-current-user';
|
||||
|
||||
const authentication = async (req: RequestWithCurrentUser, _res: Response, next: NextFunction) => {
|
||||
// We set authentication to use the sample user we created temporarily.
|
||||
|
Reference in New Issue
Block a user