fix: set trust proxy for express-rate-limit
Browse files- backend/src/app.js +1 -0
backend/src/app.js
CHANGED
|
@@ -40,6 +40,7 @@ import { errorHandler } from './middlewares/errorHandler.js';
|
|
| 40 |
import { existsSync } from 'node:fs';
|
| 41 |
|
| 42 |
const app = express();
|
|
|
|
| 43 |
|
| 44 |
app.use(helmet());
|
| 45 |
app.use(cors({ origin: config.CORS_ORIGIN, credentials: true }));
|
|
|
|
| 40 |
import { existsSync } from 'node:fs';
|
| 41 |
|
| 42 |
const app = express();
|
| 43 |
+
app.set('trust proxy', 1);
|
| 44 |
|
| 45 |
app.use(helmet());
|
| 46 |
app.use(cors({ origin: config.CORS_ORIGIN, credentials: true }));
|