🎈 perf(热更新): 添加白名单热更新地址
This commit is contained in:
@@ -282,7 +282,7 @@ class Filter {
|
||||
if(!mainten) return false // 该服务器维护
|
||||
if(mainten.startTime > nowSeconds() || mainten.endTime < nowSeconds()) return false;
|
||||
|
||||
let isWhiteList = await checkWhiteList(this.app.get('env'), ip, uid, serverId);
|
||||
let isWhiteList = await checkWhiteList(this.app.get('env'), ip, uid);
|
||||
if(isWhiteList) return false;
|
||||
|
||||
return true
|
||||
|
||||
@@ -308,7 +308,7 @@ export async function getIpLocation(ip: string) {
|
||||
|
||||
// 服务器是否开启
|
||||
export async function checkServerIsOpen(serverId: number, ip: string, uid: number) {
|
||||
let isWhiteList = await checkWhiteList(pinus.app.get('env'), ip, uid, serverId);
|
||||
let isWhiteList = await checkWhiteList(pinus.app.get('env'), ip, uid);
|
||||
if(isWhiteList) return true;
|
||||
|
||||
let serverTime = await getServerCreateTime(serverId);
|
||||
|
||||
Reference in New Issue
Block a user