com web/master: Fix not-always-set varaible notice: manage/mirrors.php
| From: | Hannes Magnusson | Date: | Tue, 26 May 2015 18:26:07 +0000 |
| Subject: | com web/master: Fix not-always-set varaible notice: manage/mirrors.php | ||
| Groups: | php.webmaster | ||
| Request: | Send a blank email to php-webmaster+get-21219@lists.php.net to get a copy of this message | ||
Commit: d6a31a36f379bd457a8a0c5348ef2049c4e14105
Author: Hannes Magnusson <bjori@php.net> Tue, 26 May 2015 11:26:07 -0700
Parents: 229c1e8b0060fe752cff75d0bc04daa5c344f8ec
Branches: master
Link: http://git.php.net/?p=web/master.git;a=commitdiff;h=d6a31a36f379bd457a8a0c5348ef2049c4e14105
Log:
Fix not-always-set varaible notice
Changed paths:
M manage/mirrors.php
Diff:
diff --git a/manage/mirrors.php b/manage/mirrors.php
index 2119a86..ad4ad80 100644
--- a/manage/mirrors.php
+++ b/manage/mirrors.php
@@ -37,7 +37,7 @@ $active = isset($active) ? 1 : 0;
$has_stats = isset($has_stats) ? 1 : 0;
$moreinfo = empty($_GET['mi']) ? 0 : 1;
-$mirrortype = (int)$mirrortype;
+$mirrortype = isset($mirrortype) ? (int)$mirrortype : 0;
// Select last mirror check time from table
$lct = db_query("SELECT UNIX_TIMESTAMP(lastchecked) FROM mirrors ORDER BY lastchecked DESC
LIMIT 1");