Skip to content

Commit

Permalink
method IsHavePlugin
Browse files Browse the repository at this point in the history
  • Loading branch information
mzhelskiy committed Dec 14, 2020
1 parent 516dcdd commit a82dda1
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion classes/engine/Engine.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -561,6 +561,15 @@ public function GetPlugins()
return $this->aPlugins;
}

public static function IsHavePlugin($sCode)
{
$aPlugins = self::getInstance()->GetPlugins();
if (isset($aPlugins[strtolower($sCode)])) {
return true;
}
return false;
}

/**
* Вызывает метод нужного модуля
*
Expand Down Expand Up @@ -1703,4 +1712,4 @@ public static function __callStatic($sName, $aArgs = array())
{
return call_user_func_array(array(self::E(), $sName), $aArgs);
}
}
}

0 comments on commit a82dda1

Please sign in to comment.