additionally check for lib/userdata.inc.php in Froxlor\System\Plugin

Signed-off-by: Michael Kaufmann <d00p@froxlor.org>
This commit is contained in:
Michael Kaufmann 2023-01-15 12:48:06 +01:00
parent c9327eb4c1
commit a1ca02ed41
No known key found for this signature in database
GPG Key ID: C121F97338D7A352

View File

@ -128,7 +128,7 @@ class Plugin
*/
public function isInstalled(): bool
{
$installed = Settings::Get($this->getPluginBasename() . '.is_installed');
$installed = file_exists(Froxlor::getInstallDir() . '/lib/userdata.inc.php') && Settings::Get($this->getPluginBasename() . '.is_installed');
return !empty($installed);
}
@ -138,7 +138,7 @@ class Plugin
*/
public function isActive(): bool
{
$active = Settings::Get($this->getPluginBasename() . '.is_active');
$active = file_exists(Froxlor::getInstallDir() . '/lib/userdata.inc.php') && Settings::Get($this->getPluginBasename() . '.is_active');
return !empty($active);
}