Skip to content

Commit

Permalink
Remove duplicate PORT variable; export the one in app.js
Browse files Browse the repository at this point in the history
  • Loading branch information
nchaloult committed May 7, 2022
1 parent e65f778 commit 3892a76
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion backend/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,4 +28,4 @@ const invoice = require('./api/invoice');
app.use('/api/v1/spot', spot);
app.use('/api/v1/invoice', invoice);

module.exports = app;
module.exports = { app, PORT };
3 changes: 1 addition & 2 deletions backend/server.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
const app = require('./app');
const PORT = process.env.PORT || 4000;
const { app, PORT } = require('./app');
const debug = require('./utils/debug');

app.listen(PORT, () => {
Expand Down

0 comments on commit 3892a76

Please sign in to comment.