...
|
...
|
@@ -17,8 +17,8 @@ const path = require('path'); |
|
|
const bodyParser = require('body-parser');
|
|
|
const cookieParser = require('cookie-parser');
|
|
|
const favicon = require('serve-favicon');
|
|
|
const session = require('yoho-express-session');
|
|
|
const memcached = require('yoho-connect-memcached');
|
|
|
const session = require('express-session');
|
|
|
const memcached = require('connect-memcached');
|
|
|
const hbs = require('express-handlebars');
|
|
|
const pkg = require('./package.json');
|
|
|
|
...
|
...
|
@@ -78,12 +78,14 @@ const logger = require('./library/logger'); |
|
|
|
|
|
// dispatcher
|
|
|
try {
|
|
|
const mobileCheck = require('./doraemon/middleware/mobile-check');
|
|
|
const user = require('./doraemon/middleware/user');
|
|
|
const seo = require('./doraemon/middleware/seo');
|
|
|
const setYohoData = require('./doraemon/middleware/set-yoho-data');
|
|
|
const errorHanlder = require('./doraemon/middleware/error-handler');
|
|
|
|
|
|
// YOHO 前置中间件
|
|
|
app.use(mobileCheck());
|
|
|
app.use(setYohoData());
|
|
|
app.use(user());
|
|
|
app.use(seo());
|
...
|
...
|
|