diff --git a/app/controllers/student_work_controller.rb b/app/controllers/student_work_controller.rb index 2849bdf90..89ee77053 100644 --- a/app/controllers/student_work_controller.rb +++ b/app/controllers/student_work_controller.rb @@ -141,11 +141,12 @@ class StudentWorkController < ApplicationController if result["status"].to_i != -2 result["results"].first['user_wait'] = tUsedtime + + if result["results"][0]["status"].to_i == 2 + result["status"] = 2 + end end - if result["results"][0]["status"].to_i == 2 - result["status"] = 2 - end status = result["status"] if index == 1 student_work_test = student_work.student_work_tests.build(status: status,