军团活动:粮草先行精度问题
This commit is contained in:
@@ -155,10 +155,6 @@ Filter.prototype.before = async function (routeRecord: RouteRecord, msg: any, se
|
||||
case 'guild.guildHandler.createGuild':
|
||||
case 'guild.guildHandler.setGuildInfo':
|
||||
{
|
||||
if(!guildCode) {
|
||||
guildCode = genCode(6);
|
||||
msg.guildCode = guildCode;
|
||||
}
|
||||
let result = await checkGuildName(guildCode, serverId, msg.name, msg.notice);
|
||||
if(!result) hasBlockWords = true;
|
||||
break;
|
||||
@@ -166,6 +162,11 @@ Filter.prototype.before = async function (routeRecord: RouteRecord, msg: any, se
|
||||
}
|
||||
}
|
||||
|
||||
if(routeRecord.route == 'guild.guildHandler.createGuild') {
|
||||
let guildCode = genCode(6);
|
||||
msg.guildCode = guildCode;
|
||||
}
|
||||
|
||||
if(hasBlockWords) return next(new Error('globalFilter'), resResult(STATUS.BLOCK_WORDS));
|
||||
|
||||
next(null);
|
||||
|
||||
@@ -53,6 +53,7 @@ export function guild(session: Session, msg: any, app: Application, cb: (err: Er
|
||||
|
||||
let rid = session.get('roleId');
|
||||
|
||||
console.log('#### arg', msg.args);
|
||||
if (msg.args && msg.args.length > 0) {
|
||||
for (let arg of msg.args) {
|
||||
if (!arg.route) continue;
|
||||
|
||||
Reference in New Issue
Block a user