Refactor code structure for improved readability and maintainability; optimize performance across multiple modules.
All checks were successful
Deploy to production / deploy (push) Successful in 2m56s
All checks were successful
Deploy to production / deploy (push) Successful in 2m56s
This commit is contained in:
12
backend/routers/pushNotificationRouter.js
Normal file
12
backend/routers/pushNotificationRouter.js
Normal file
@@ -0,0 +1,12 @@
|
||||
import express from 'express';
|
||||
import { authenticate } from '../middleware/authMiddleware.js';
|
||||
import pushNotificationController from '../controllers/pushNotificationController.js';
|
||||
|
||||
const router = express.Router();
|
||||
router.use(authenticate);
|
||||
router.put('/devices', pushNotificationController.registerDevice);
|
||||
router.delete('/devices/:token', pushNotificationController.disableDevice);
|
||||
router.get('/settings', pushNotificationController.getSettings);
|
||||
router.put('/settings', pushNotificationController.updateSettings);
|
||||
|
||||
export default router;
|
||||
Reference in New Issue
Block a user