diff --git a/index.js b/index.js index 636f831..9bdca88 100644 --- a/index.js +++ b/index.js @@ -10,7 +10,8 @@ app.use(express.static(clientPath)); const server = http.createServer(app); app.post('/message', (req, res) => { - const { user, message } = req.body; + const { id, message } = req.body; + console.log(`User '${id}' sent message '${message}'.`); res.status(200).json({message}); });