Fixed constants

This commit is contained in:
Dmitry Khomutov 2016-07-21 21:20:34 +06:00
commit 4fee89fb80
46 changed files with 204 additions and 212 deletions

View file

@ -63,7 +63,7 @@ class Campfire implements Plugin
*/
public function execute()
{
$url = PHPCI_URL . "build/view/" . $this->build->getId();
$url = APP_URL . "build/view/" . $this->build->getId();
$message = str_replace("%buildurl%", $url, $this->message);
$this->joinRoom($this->roomId);
$status = $this->speak($message, $this->roomId);

View file

@ -69,7 +69,7 @@ class Mysql implements Plugin
$config = Database::getConnection('write')->getDetails();
$this->host =(defined('PHPCI_DB_HOST')) ? PHPCI_DB_HOST : null;
$this->host =(defined('DB_HOST')) ? DB_HOST : null;
$this->user = $config['user'];
$this->pass = $config['pass'];

View file

@ -10,9 +10,9 @@ use Pimple\Container;
*/
class Factory
{
const TYPE_ARRAY = "array";
const TYPE_CALLABLE = "callable";
const INTERFACE_PHPCI_PLUGIN = '\PHPCensor\Plugin';
const TYPE_ARRAY = "array";
const TYPE_CALLABLE = "callable";
const INTERFACE_PLUGIN = '\PHPCensor\Plugin';
private $currentPluginOptions;
@ -79,9 +79,9 @@ class Factory
$reflectedPlugin = new \ReflectionClass($className);
if (!$reflectedPlugin->implementsInterface(self::INTERFACE_PHPCI_PLUGIN)) {
if (!$reflectedPlugin->implementsInterface(self::INTERFACE_PLUGIN)) {
throw new \InvalidArgumentException(
"Requested class must implement " . self:: INTERFACE_PHPCI_PLUGIN
"Requested class must implement " . self:: INTERFACE_PLUGIN
);
}