Sfoglia il codice sorgente

Merge branch 'master' of https://github.com/boonex/dolphin

AntonLV 12 anni fa
parent
commit
b95a241cfb
1 ha cambiato i file con 8 aggiunte e 1 eliminazioni
  1. 8 1
      inc/classes/BxDolUpgrader.php

+ 8 - 1
inc/classes/BxDolUpgrader.php

@@ -85,9 +85,16 @@ class BxDolUpgrader extends BxDol
         return $a;
     }
 
+    public function isNewVersionAvailable ($a)
+    {
+        if (1 == version_compare(strtolower($a['latest_version']), strtolower(bx_get_ver())))
+            return true;
+        return false;
+    }
+
     public function isUpgradeAvailable ($a)
     {
-        if (1 == version_compare(strtolower($a['latest_version']), strtolower(bx_get_ver())) && isset($a['patch']))
+        if ($this->isNewVersionAvailable($a) && isset($a['patch']))
             return true;
         return false;
     }