underscore读取,排行榜保护
This commit is contained in:
@@ -10,7 +10,7 @@ import Counter from '@db/Counter';
|
||||
import { getHeroInfoById } from 'app/pubUtils/gamedata';
|
||||
import { calPlayerCeAndSave } from 'app/pubUtils/playerCe';
|
||||
import { getExpByLv, getHeroExpByLv, gameData } from 'app/pubUtils/data';
|
||||
const _ = require('underscore');
|
||||
import { isString } from 'underscore';
|
||||
|
||||
/**
|
||||
* Test Service
|
||||
@@ -18,7 +18,7 @@ const _ = require('underscore');
|
||||
export default class Auth extends Service {
|
||||
|
||||
public checkTelNo(telNo) {
|
||||
if (!_.isString(telNo)) {
|
||||
if (!isString(telNo)) {
|
||||
return { status: 1, data: '参数类型错误' };
|
||||
}
|
||||
if (telNo.length !== 11) {
|
||||
@@ -92,7 +92,7 @@ export default class Auth extends Service {
|
||||
if (telVerify.status !== 0) {
|
||||
return telVerify;
|
||||
}
|
||||
if (!_.isString(code) || code.length !== 6) {
|
||||
if (!isString(code) || code.length !== 6) {
|
||||
return ctx.service.utils.resResult(STATUS.WRONG_PARMS);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user