disabled direct actions for deactivated modules (because of duplicate modules)
This commit is contained in:
parent
21db8ace76
commit
645404c82d
@ -74,12 +74,16 @@ class Backend extends dcNsProcess
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Perfom direct action on module deletion.
|
* Perfom direct action on module deletion.
|
||||||
|
*
|
||||||
|
* This does not perform action on disabled module.
|
||||||
*
|
*
|
||||||
* @param dcModuleDefine $define The module
|
* @param dcModuleDefine $define The module
|
||||||
*/
|
*/
|
||||||
protected static function moduleBeforeDelete(dcModuleDefine $define): void
|
protected static function moduleBeforeDelete(dcModuleDefine $define): void
|
||||||
{
|
{
|
||||||
if (dcCore::app()->blog?->settings->get('system')->get('no_uninstall_direct')) {
|
if (dcCore::app()->blog?->settings->get('system')->get('no_uninstall_direct')
|
||||||
|
|| $define->get('state') != dcModuleDefine::STATE_ENABLED
|
||||||
|
) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user