Chapter 6: code samples
This commit is contained in:
@@ -0,0 +1,8 @@
|
||||
module.exports = logger;
|
||||
|
||||
function logger() {
|
||||
return async (ctx, next) => {
|
||||
console.log("Request received:", ctx.req.method, ctx.req.url);
|
||||
await next();
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user