Improve status detection
This commit is contained in:
parent
9a5f6d1d27
commit
24cfa48988
1 changed files with 1 additions and 1 deletions
|
@ -11,13 +11,13 @@ function urlStatus(url, cb){
|
||||||
}
|
}
|
||||||
|
|
||||||
function checkDownload(url){
|
function checkDownload(url){
|
||||||
|
document.buildingfw = true;
|
||||||
urlStatus(url, function(status) {
|
urlStatus(url, function(status) {
|
||||||
if (status === 200){
|
if (status === 200){
|
||||||
document.buildingfw = false;
|
document.buildingfw = false;
|
||||||
document.getElementById("download").src=url;
|
document.getElementById("download").src=url;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
document.buildingfw = true;
|
|
||||||
checkDownload(url);
|
checkDownload(url);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in a new issue