cvs: php-master-web /fetch mirrors.php

From: Date: Sat, 21 Dec 2002 16:46:02 +0000
Subject: cvs: php-master-web /fetch mirrors.php
Groups: php.mirrors 
Request: Send a blank email to php-mirrors+get-14409@lists.php.net to get a copy of this message
goba Sat Dec 21 11:46:02 2002 EDT Modified files: /php-master-web/fetch mirrors.php Log: Special mirrors are always OK, now they don't have the uptodate check... Index: php-master-web/fetch/mirrors.php diff -u php-master-web/fetch/mirrors.php:1.13 php-master-web/fetch/mirrors.php:1.14 --- php-master-web/fetch/mirrors.php:1.13 Sat Dec 21 09:40:44 2002 +++ php-master-web/fetch/mirrors.php Sat Dec 21 11:46:02 2002 @@ -64,25 +64,30 @@ case MIRROR_STANDARD : $row['mirrortype'] = 'MIRROR_STANDARD'; break; case MIRROR_SPECIAL : $row['mirrortype'] = 'MIRROR_SPECIAL'; break; } - + // Rewrirte has_search and has_stats to be booleans $row["has_search"] = ($row["has_search"] ? 'TRUE' : 'FALSE'); $row["has_stats"] = ($row["has_stats"] ? 'TRUE' : 'FALSE'); - + // Presumably the mirror is all right $status = 'MIRROR_OK'; - - // Set inactive mirrors to special (for backward compatibilty), - // and provide status information computed from current information - if (!$row["active"]) { - $row["mirrortype"] = 'MIRROR_SPECIAL'; - $status = 'MIRROR_NOTACTIVE'; - } elseif (!$row["current"]) { - $row["mirrortype"] = 'MIRROR_SPECIAL'; - $status = 'MIRROR_OUTDATED'; - } elseif (!$row["up"]) { - $row["mirrortype"] = 'MIRROR_SPECIAL'; - $status = 'MIRROR_DOESNOTWORK'; + + // Non-special mirrors have an uptodate check + if ($row['mirrortype'] != 'MIRROR_SPECIAL') { + + // Set inactive mirrors to special (for backward compatibilty), + // and provide status information computed from current information + if (!$row["active"]) { + $row["mirrortype"] = 'MIRROR_SPECIAL'; + $status = 'MIRROR_NOTACTIVE'; + } elseif (!$row["current"]) { + $row["mirrortype"] = 'MIRROR_SPECIAL'; + $status = 'MIRROR_OUTDATED'; + } elseif (!$row["up"]) { + $row["mirrortype"] = 'MIRROR_SPECIAL'; + $status = 'MIRROR_DOESNOTWORK'; + } + } // Print out the array element for this mirror

« previous php.mirrors (#14409) next »