version fix
This commit is contained in:
@ -9,6 +9,7 @@ use kernel\helpers\Debug;
|
||||
use kernel\helpers\Files;
|
||||
use kernel\helpers\Manifest;
|
||||
use kernel\helpers\RESTClient;
|
||||
use kernel\helpers\Version;
|
||||
use kernel\models\Option;
|
||||
use ZipArchive;
|
||||
|
||||
@ -449,8 +450,11 @@ class ModuleService
|
||||
$modules_info = json_decode($modules_info->getBody()->getContents(), true);
|
||||
|
||||
$mod_info = $this->getModuleInfoBySlug($slug);
|
||||
|
||||
$currentVersion = Version::getIntVersionByString($mod_info['version']);
|
||||
foreach ($modules_info as $mod) {
|
||||
if ($mod['slug'] === $mod_info['slug'] && $mod['version'] === $mod_info['version']) {
|
||||
$modVersion = Version::getIntVersionByString($mod['version']);
|
||||
if ($mod['slug'] === $mod_info['slug'] && $modVersion <= $currentVersion) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user