mirror of
https://github.com/sct/overseerr.git
synced 2025-09-17 17:24:35 +02:00
Settings System (#46)
* feat(api): settings system Also includes /auth/me endpoint for ticket ch76 and OpenAPI 3.0 compatibility for ch77 * refactor(api): remove unused imports
This commit is contained in:
@@ -2,11 +2,13 @@ import { Router } from 'express';
|
||||
import user from './user';
|
||||
import authRoutes from './auth';
|
||||
import { checkUser, isAuthenticated } from '../middleware/auth';
|
||||
import settingsRoutes from './settings';
|
||||
|
||||
const router = Router();
|
||||
|
||||
router.use(checkUser);
|
||||
router.use('/user', isAuthenticated, user);
|
||||
router.use('/settings', isAuthenticated, settingsRoutes);
|
||||
router.use('/auth', authRoutes);
|
||||
|
||||
router.get('/', (req, res) => {
|
||||
@@ -16,8 +18,4 @@ router.get('/', (req, res) => {
|
||||
});
|
||||
});
|
||||
|
||||
router.all('*', (req, res) =>
|
||||
res.status(404).json({ status: 404, message: '404 Not Found' })
|
||||
);
|
||||
|
||||
export default router;
|
||||
|
Reference in New Issue
Block a user