From 422e5970522bf5defb17559a0e67eb5176854603 Mon Sep 17 00:00:00 2001 From: aozhiwei Date: Tue, 27 Oct 2020 15:20:56 +0800 Subject: [PATCH] 1 --- tools/rankserver/app.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/tools/rankserver/app.py b/tools/rankserver/app.py index c3ee812..87a5131 100644 --- a/tools/rankserver/app.py +++ b/tools/rankserver/app.py @@ -39,9 +39,9 @@ def getRedisConf(): def checkchannel(channel): if channel == 6006: - return false + return False else: - return true + return True def info(msg): print(str(datetime.datetime.now()) + '[INFO] ' + msg) @@ -137,19 +137,19 @@ def fullUpdateRank(): has_data = True #更新击杀榜 channel = f7.getChannelByAccountId(row[0]) - if checkchannel(channel) == true: + if checkchannel(channel): if channel not in kill_hash: kill_hash[channel] = [] _refreshData(row, kill_hash[channel], take_kills) #更新胜场榜 channel = f7.getChannelByAccountId(row[0]) - if checkchannel(channel) == true: + if checkchannel(channel): if channel not in win_hash: win_hash[channel] = [] _refreshData(row, win_hash[channel], take_game_times) #更新积分榜 channel = f7.getChannelByAccountId(row[0]) - if checkchannel(channel) == true: + if checkchannel(channel): if channel not in integral_hash: integral_hash[channel] = [] _refreshData(row, integral_hash[channel], take_integral_times) @@ -201,7 +201,7 @@ def incrementUpdateRank(): for row in cursor: has_data = True channel = f7.getChannelByAccountId(row[0]) - if checkchannel(channel) == true: + if checkchannel(channel): #更新击杀榜 if channel not in kill_hash: kill_list = r.get('game2004api:kill_rank_' + channel)