From 75d7927604d6155a67f7fe2cc132e79f2aaf7b10 Mon Sep 17 00:00:00 2001 From: Madhura Jayaratne Date: Mon, 21 Sep 2015 21:37:55 +1000 Subject: [PATCH] Do not suggest upgrading when there is no compatible versions Signed-off-by: Madhura Jayaratne --- setup/lib/index.lib.php | 5 ++--- version_check.php | 5 ++--- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/setup/lib/index.lib.php b/setup/lib/index.lib.php index b17fac07a5..ac07d27db9 100644 --- a/setup/lib/index.lib.php +++ b/setup/lib/index.lib.php @@ -129,9 +129,8 @@ function PMA_versionCheck() if ($latestCompatible != null) { $version = $latestCompatible['version']; $date = $latestCompatible['date']; - } else { // fallback to old behavior - $version = $versionDetials->version; - $date = $versionDetials->date; + } else { + return; } $version_upstream = $versionInformation->versionToInt($version); diff --git a/version_check.php b/version_check.php index e1f2be985b..0f7f11cafa 100644 --- a/version_check.php +++ b/version_check.php @@ -24,12 +24,11 @@ if (empty($versionDetails)) { $latestCompatible = $versionInformation->getLatestCompatibleVersion( $versionDetails->releases ); + $version = ''; + $date = ''; if ($latestCompatible != null) { $version = $latestCompatible['version']; $date = $latestCompatible['date']; - } else { // fallback to old behavior - $version = $versionDetails->version; - $date = $versionDetails->date; } echo json_encode( array(