Back to ComponentHelper class

Method isEnabled

public static bool
isEnabled
(mixed $option)
Checks if the component is enabled
Parameters
  • string $option The component option.
Returns
  • bool
Since
  • 1.5

Method isEnabled - Source code

/**
 * Checks if the component is enabled
 *
 * @param   string  $option  The component option.
 *
 * @return  boolean
 *
 * @since   1.5
 */
public static function isEnabled($option)
{
    $components = static::getComponents();
    return isset($components[$option]) && $components[$option]->enabled;
}