From 3b48b566fbffc8e682e4e667e15d9539a5e8464d Mon Sep 17 00:00:00 2001 From: virusdefender <1670873886@qq.com> Date: Sat, 10 Oct 2015 10:50:26 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B8=85=E9=99=A4=E7=BC=93=E5=AD=98=E7=9A=84?= =?UTF-8?q?=E9=80=BB=E8=BE=91=E5=86=99=E5=8F=8D=E4=BA=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- contest/views.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contest/views.py b/contest/views.py index 113e640..c118855 100644 --- a/contest/views.py +++ b/contest/views.py @@ -118,7 +118,7 @@ class ContestAdminAPIView(APIView): return error_response(u"比赛的开始时间必须早于比赛结束的时间") # 之前是封榜,现在要开放,需要清除缓存 - if contest.real_time_rank == True and data["real_time_rank"] == False: + if contest.real_time_rank == False and data["real_time_rank"] == True: r = redis.Redis(host=settings.REDIS_CACHE["host"], port=settings.REDIS_CACHE["port"], db=settings.REDIS_CACHE["db"]) cache_key = str(contest.id) + "_rank_cache" r.delete(cache_key)