系统:添加1003报错返回

This commit is contained in:
luying
2021-04-21 17:08:01 +08:00
parent 1c127afe5e
commit 1dc2be9230
2 changed files with 4 additions and 3 deletions
+3 -3
View File
@@ -1,5 +1,5 @@
require('xprofiler').start();
import { COM_TEAM_STATUS } from './app/consts';
import { COM_TEAM_STATUS, STATUS } from './app/consts';
import {
createTcpAcceptor,
createTcpMailBox,
@@ -23,7 +23,7 @@ import * as redLockService from './app/services/redLockService';
import _pinus = require('pinus');
import { updateTeamStatus } from './app/services/comBattleService';
import { init } from './app/pubUtils/gmData/gmDataUtil';
import { gameData } from './app/pubUtils/data';
import { resResult } from './app/pubUtils/util';
const filePath = (_pinus as any).FILEPATH;
filePath.MASTER = '/config/master';
filePath.SERVER = '/config/servers';
@@ -149,7 +149,7 @@ function errorHandler(err: Error, msg: any, resp: any,
to resolve unknown exception: sessionId:${ JSON.stringify(session.export()) } ,
error stack: ${ err.stack }`);
if (!resp) {
resp = { code: 1003 };
resp = resResult(STATUS.GLOBAL_ERR);
}
cb(err, resp);
}