fix multi install (only activate module has user action)
This commit is contained in:
parent
281ab72dda
commit
6c4756ed84
@ -15,6 +15,7 @@ declare(strict_types=1);
|
|||||||
namespace Dotclear\Plugin\Uninstaller;
|
namespace Dotclear\Plugin\Uninstaller;
|
||||||
|
|
||||||
use dcCore;
|
use dcCore;
|
||||||
|
use dcModuleDefine;
|
||||||
use dcNsProcess;
|
use dcNsProcess;
|
||||||
use dcPage;
|
use dcPage;
|
||||||
use dcThemes;
|
use dcThemes;
|
||||||
@ -59,7 +60,7 @@ class Manage extends dcNsProcess
|
|||||||
}
|
}
|
||||||
|
|
||||||
// get selected module
|
// get selected module
|
||||||
$define = dcCore::app()->{self::getType() . 's'}->getDefine($_REQUEST['id']);
|
$define = dcCore::app()->{self::getType() . 's'}->getDefine($_REQUEST['id'], ['state' => dcModuleDefine::STATE_ENABLED]);
|
||||||
if (!$define->isDefined()) {
|
if (!$define->isDefined()) {
|
||||||
dcCore::app()->error->add(__('Unknown module id to uninstall'));
|
dcCore::app()->error->add(__('Unknown module id to uninstall'));
|
||||||
self::doRedirect();
|
self::doRedirect();
|
||||||
@ -114,7 +115,7 @@ class Manage extends dcNsProcess
|
|||||||
}
|
}
|
||||||
|
|
||||||
// load module uninstaller
|
// load module uninstaller
|
||||||
$define = dcCore::app()->{self::getType() . 's'}->getDefine($_REQUEST['id']);
|
$define = dcCore::app()->{self::getType() . 's'}->getDefine($_REQUEST['id'], ['state' => dcModuleDefine::STATE_ENABLED]);
|
||||||
$uninstaller = Uninstaller::instance()->loadModules([$define]);
|
$uninstaller = Uninstaller::instance()->loadModules([$define]);
|
||||||
$fields = [];
|
$fields = [];
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user