From dce940523ae7a3ce10d8ee01da60a75e84edfc07 Mon Sep 17 00:00:00 2001 From: daiao <358551898@qq.com> Date: Tue, 28 May 2019 21:21:21 +0800 Subject: [PATCH] 1 --- app/services/cnmoocs_service.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/services/cnmoocs_service.rb b/app/services/cnmoocs_service.rb index e1bae88d..a30e2ef2 100644 --- a/app/services/cnmoocs_service.rb +++ b/app/services/cnmoocs_service.rb @@ -129,7 +129,7 @@ class CnmoocsService # shixun_ids = StageShixun.where(:stage_id => subject.stages).pluck(:shixun_id) #myshixuns = Myshixun.where(:user_id => params[:userId], shixun_id: shixun_ids).includes(:games) myshixun = shixun.myshixuns.where(:user_id => params[:userId]).includes(:games) - if myshixun + if myshixun.present? score = myshixun.total_score time = 0 myshixun.games.each do |game|