fix worker

This commit is contained in:
umorist 2026-03-10 11:52:28 +03:00
parent dbb67583fe
commit 16bb81bd2f

View file

@ -64,7 +64,7 @@ function fetchRoutes() {
// routeModel.append(response[i]);
//}
} else {
WorkerScript.sendMessage({ "action": "fetch_routes", "data": [{"code":"ERR","name":"Error, please try again :<","provider":xhr.status}] });
//WorkerScript.sendMessage({ "action": "fetch_routes", "data": [{"code":"ERR","name":"Error, please try again :<","provider":xhr.status}] });
console.error("Failed to fetch routes:", xhr.status);
}
}
@ -95,7 +95,7 @@ function fetchProfile() {
// profileModel.append(response[i]);
//}
} else {
WorkerScript.sendMessage({ "action": "fetch_profile", "data": {"provider":xhr.status, "current_device":"error"} });
//WorkerScript.sendMessage({ "action": "fetch_profile", "data": {"provider":xhr.status, "current_device":"error"} });
console.error("Failed to fetch profile:", xhr.status);
}
}
@ -126,7 +126,7 @@ function fetchStats() {
// profileModel.append(response[i]);
//}
} else {
WorkerScript.sendMessage({ "action": "fetch_stats", "data": {} });
//WorkerScript.sendMessage({ "action": "fetch_stats", "data": {} });
console.error("Failed to fetch profile:", xhr.status);
}
}