mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-11-30 21:40:39 +03:00
Moved log-request mw into parent app
- Moved log-request from shared to parent as it is not shared - This file is only used in one place, this updates the code structure to reflect this - This is one of many similar changes needed to make it easier to refactor to the existing setup
This commit is contained in:
parent
8fe56852e0
commit
e53baac13d
@ -22,7 +22,7 @@ module.exports = function setupParentApp(options = {}) {
|
||||
parentApp.enable('trust proxy');
|
||||
|
||||
parentApp.use(mw.requestId);
|
||||
parentApp.use(shared.middlewares.logRequest);
|
||||
parentApp.use(mw.logRequest);
|
||||
|
||||
// Register event emmiter on req/res to trigger cache invalidation webhook event
|
||||
parentApp.use(shared.middlewares.emitEvents);
|
||||
|
@ -1,3 +1,4 @@
|
||||
module.exports = {
|
||||
logRequest: require('./log-request'),
|
||||
requestId: require('./request-id')
|
||||
};
|
||||
|
@ -39,10 +39,6 @@ module.exports = {
|
||||
return require('./labs');
|
||||
},
|
||||
|
||||
get logRequest() {
|
||||
return require('./log-request');
|
||||
},
|
||||
|
||||
get maintenance() {
|
||||
return require('./maintenance');
|
||||
},
|
||||
|
Loading…
Reference in New Issue
Block a user