diff --git a/package-lock.json b/package-lock.json index bba8b89..f7f346a 100644 --- a/package-lock.json +++ b/package-lock.json @@ -55,8 +55,8 @@ "@types/mailgun-js": "^0.22.18", "@types/mocha": "^10.0.7", "@types/morgan": "^1.9.9", - "@types/node": "^20.14.9", "@types/multer": "^1.4.11", + "@types/node": "^20.14.9", "@types/node-cron": "^3.0.11", "@types/node-fetch": "^2.6.11", "@types/nodemailer": "^6.4.15", diff --git a/src/routes/checkoutRoutes.ts b/src/routes/checkoutRoutes.ts index 221269b..1f53532 100644 --- a/src/routes/checkoutRoutes.ts +++ b/src/routes/checkoutRoutes.ts @@ -10,7 +10,7 @@ import { } from '../controller/cartController'; const checkoutRoutes = Router(); -checkoutRoutes.use(IsLoggedIn, checkRole(['Buyer'])); +checkoutRoutes.use(IsLoggedIn, checkRole(['Buyer', 'Admin'])); checkoutRoutes.route('/').post(checkout); checkoutRoutes.route('/removeall-order').delete(deleteAllOrders); checkoutRoutes.route('/getall-order').get(getAllOrders);