正在评测中

!status && status !== 0
dev_hjm
hjm 6 years ago
parent 6786b6ee10
commit 27240407a0

@ -644,18 +644,18 @@ class MainContentContainer extends Component {
axios.get(game_status_url, {
withCredentials: true,
}).then((gameStatusResponse) => {
requestTimes++;
if(!gameStatusResponse.data || gameStatusResponse.data.statusMessage
&& gameStatusResponse.data.messageStatus ) {
requestTimes++;
const { status, running_code_message } = gameStatusResponse.data;
if(!gameStatusResponse.data || !status && status !== 0 ) {
if(requestTimes >= timeOut - 1) { // 最后一次参数改为true
timeOutFlag = true;
}
if (gameStatusResponse.data.statusMessage) {
this.setEvaluateMiddleStatusText(gameStatusResponse.data.statusMessage)
}
timeOutFlag = true;
}
if (running_code_message) {
this.setEvaluateMiddleStatusText(running_code_message)
}
return;
}
const { status } = gameStatusResponse.data;
if (timeOutFlag === false && (status === 2 || status === 0)) {
// 网络太慢或服务处理较慢的情况下,可能这里会执行第二次

Loading…
Cancel
Save