/** * Check if plugin is enabled for server and optional channel. * @param Dog_Server $server * @param DOG_Channel $channel * @return boolean */ public function isEnabled(Dog_Server $server, $channel) { $plg = $this->name; if (Dog_Conf_Plug::isDisabled($plg) || Dog_Conf_Plug_Serv::isDisabled($plg, $server->getID()) || $channel !== false && Dog_Conf_Plug_Chan::isDisabled($plg, $channel->getID(), $this->defdis)) { return false; } return true; }