From 82e7b5b1817e5a923da65fb5fc3cd2915ae08c4a Mon Sep 17 00:00:00 2001 From: t123yh Date: Tue, 22 Aug 2017 16:26:09 +0800 Subject: [PATCH] Close socket in submission_content. --- views/submission_content.ejs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/views/submission_content.ejs b/views/submission_content.ejs index fb478a1..92e8fff 100644 --- a/views/submission_content.ejs +++ b/views/submission_content.ejs @@ -222,6 +222,7 @@ if (token != null) { vueApp.roughData.running = false; vueApp.roughData.result = p.roughResult; vueApp.detailResult = p.result; + socket.close(); }); socket.emit('join', token, (data) => { console.log("JOIN" + JSON.stringify(data)); @@ -231,6 +232,7 @@ if (token != null) { vueApp.detailResult = data.result || { systemMessage: "系统出错,请刷新后重试。" }; + socket.close(); } else { if (data.current.running) { vueApp.roughData.running = true;