X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=admin%2Finst_module.php;h=886ecc91a628f6823879e92a96f172e5dc772f83;hb=43ad91751a494b2572eb64441248aa3a87f0141e;hp=71d6f7424200b1634439de6b4fca394bc159a6db;hpb=f0f7b444137a81aa1a227cbb041f3d7d7eaa1715;p=fa-stable.git diff --git a/admin/inst_module.php b/admin/inst_module.php index 71d6f742..886ecc91 100644 --- a/admin/inst_module.php +++ b/admin/inst_module.php @@ -210,18 +210,10 @@ if (get_post('Refresh')) { $result = true; foreach($exts as $i => $ext) { - if ($ext['package'] && ($ext['active'] ^ check_value('Active'.$i))) { - if (check_value('Active'.$i) && !check_src_ext_version($ext['version'])) - { - display_warning(sprintf(_("Package '%s' is incompatible with current application version and cannot be activated.\n") - . _("Check Install/Activate page for newer package version."), $ext['name'])); - continue; - } - if (!$ext['active']) - $activated = activate_hooks($ext['package'], $comp); - else - $activated = hook_invoke($ext['package'], check_value('Active'.$i) ? - 'activate_extension':'deactivate_extension', $comp, false); + if ($ext['package'] && ($ext['active'] ^ check_value('Active'.$i))) + { + $activated = activate_hooks($ext['package'], $comp, !$ext['active']); // change active state + if ($activated !== null) $result &= $activated; if ($activated || ($activated === null))