Audit changes
This commit is contained in:
@@ -7,6 +7,7 @@ import helmet from 'helmet';
|
||||
import routes from './routes';
|
||||
import logger from './utils/logger';
|
||||
import { testConnection } from './config/database';
|
||||
import { auditMiddleware } from './middleware/audit.middleware';
|
||||
|
||||
const app: Application = express();
|
||||
|
||||
@@ -42,6 +43,9 @@ app.use(cors({
|
||||
app.use(express.json({ limit: '10mb' }));
|
||||
app.use(express.urlencoded({ extended: true, limit: '10mb' }));
|
||||
|
||||
// Audit logging middleware (before routes)
|
||||
app.use(auditMiddleware);
|
||||
|
||||
// Health check endpoint
|
||||
app.get('/health', (_req: Request, res: Response) => {
|
||||
res.status(200).json({
|
||||
|
||||
Reference in New Issue
Block a user