Skip to content

Commit

Permalink
remove pseudo InstanceConfig defaults
Browse files Browse the repository at this point in the history
  • Loading branch information
AD7six committed Mar 29, 2014
1 parent b9bad84 commit e60797a
Showing 1 changed file with 6 additions and 13 deletions.
19 changes: 6 additions & 13 deletions src/Log/Engine/SyslogLog.php
Expand Up @@ -24,6 +24,8 @@
class SyslogLog extends BaseLog {

/**
* Default config for this class
*
* By default messages are formatted as:
* level: message
*
Expand All @@ -49,12 +51,14 @@ class SyslogLog extends BaseLog {
*
* @var array
*/
protected $_defaults = array(
protected $_defaultConfig = [
'levels' => [],
'scopes' => [],
'format' => '%s: %s',
'flag' => LOG_ODELAY,
'prefix' => '',
'facility' => LOG_USER
);
];

/**
* Used to map the string names back to their LOG_* constants
Expand All @@ -79,17 +83,6 @@ class SyslogLog extends BaseLog {
*/
protected $_open = false;

/**
* Make sure the configuration contains the format parameter, by default it uses
* the error number and the type as a prefix to the message
*
* @param array $config
*/
public function __construct($config = array()) {
$config += $this->_defaults;
parent::__construct($config);
}

/**
* Writes a message to syslog
*
Expand Down

0 comments on commit e60797a

Please sign in to comment.