测试环境gameing的时间改为30秒

This commit is contained in:
zhl 2021-02-05 20:57:53 +08:00
parent 2a21b62ada
commit f552c45306

View File

@ -13,6 +13,7 @@ import {
import { fetchAccount } from '../dao/AccountDao'
import { generateId } from '../utils/security.util'
import { getRandom } from '../utils/number.util'
const isProd = process.env.NODE_ENV === 'production'
export default class AccountController extends BaseController {
@role('anon')
@ -50,7 +51,8 @@ export default class AccountController extends BaseController {
let account = req.user
let {isMatch} = req.params
if (isMatch) {
await setGameing(account._id, 15 * 60)
const time = isProd? 15 * 60 : 30
await setGameing(account._id, time)
}
return {
accountid: account._id,