Skip to content

Commit

Permalink
Bug fix for son decode #1337
Browse files Browse the repository at this point in the history
  • Loading branch information
abrookbanks committed Nov 3, 2016
1 parent 26e9ce3 commit 48c32ca
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions admin/sources/maintenance.index.inc.php
Original file line number Diff line number Diff line change
Expand Up @@ -547,9 +547,10 @@ function cleanImageCache($path = null) {
$request->setData(array('version' => CC_VERSION));

if (($response = $request->send()) !== false) {
if (version_compare(trim($response['version']), CC_VERSION, '>')) {
$GLOBALS['smarty']->assign('OUT_OF_DATE', sprintf($lang['dashboard']['error_version_update'], $response['version'], CC_VERSION));
$GLOBALS['smarty']->assign('LATEST_VERSION', $response['version']);
$response_array = json_decode($response, true);
if (version_compare(trim($response_array['version']), CC_VERSION, '>')) {
$GLOBALS['smarty']->assign('OUT_OF_DATE', sprintf($lang['dashboard']['error_version_update'], $response_array['version'], CC_VERSION));
$GLOBALS['smarty']->assign('LATEST_VERSION', $response_array['version']);
$GLOBALS['smarty']->assign('UPGRADE_NOW', $lang['maintain']['upgrade_now']);
$GLOBALS['smarty']->assign('FORCE', '0');
} else {
Expand Down

0 comments on commit 48c32ca

Please sign in to comment.