mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-17 22:57:21 +01:00
fix: move attachMiddlwares function so mongoose models have tx strings
This commit is contained in:
@@ -2,7 +2,6 @@ import nconf from 'nconf';
|
||||
import logger from './libs/logger';
|
||||
import express from 'express';
|
||||
import http from 'http';
|
||||
import attachMiddlewares from './middlewares/index';
|
||||
import Bluebird from 'bluebird';
|
||||
|
||||
global.Promise = Bluebird;
|
||||
@@ -13,8 +12,11 @@ const app = express();
|
||||
app.set('port', nconf.get('PORT'));
|
||||
|
||||
// Setup translations
|
||||
// Must come before attach middlwares so Mongoose validations can use translations
|
||||
import './libs/i18n';
|
||||
|
||||
import attachMiddlewares from './middlewares/index';
|
||||
|
||||
// Load config files
|
||||
import './libs/setupMongoose';
|
||||
import './libs/setupPassport';
|
||||
|
||||
Reference in New Issue
Block a user