Implement a root level request logger middleware

Tell us what’s happening:
Root level logger middleware should be active

Your code so far
app.use(function middleware(req, res, next) => {

console.log(req.method + " " + req.path + " - " + req.ip)

next();

})

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/88.0.4324.150 Safari/537.36.

Challenge: Implement a Root-Level Request Logger Middleware

Link to the challenge:

Hi I finally got mine to work. Here’s my code, hope this helps.

Bildschirmfoto von 2021-02-25 19-12-01

Every space in the console.log function matters.
And the order matters, too.