Skip to content

Commit

Permalink
Add trust proxy setting to app.js
Browse files Browse the repository at this point in the history
  • Loading branch information
jordan-dalby committed Oct 23, 2024
1 parent b2a7f7b commit 398958c
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions server/src/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ const port = process.env.PORT || 5000;
app.use(bodyParser.json());
app.use(express.static(path.join(__dirname, '../../client/build')));

app.set('trust proxy', true);

app.use('/api/snippets', snippetRoutes);

app.get('*', (req, res) => {
Expand Down

0 comments on commit 398958c

Please sign in to comment.