initial commit
This commit is contained in:
11
src/middleware/index.js
Normal file
11
src/middleware/index.js
Normal file
@@ -0,0 +1,11 @@
|
||||
// eslint-disable-next-line no-unused-vars
|
||||
module.exports = function (app) {
|
||||
// Add your custom middleware here. Remember, that
|
||||
// in Express the order matters
|
||||
|
||||
// add req.ip to feathers
|
||||
app.use((req, res, next) => {
|
||||
req.feathers.ip = req.ip;
|
||||
next();
|
||||
});
|
||||
};
|
||||
Reference in New Issue
Block a user