Skip to content

Commit

Permalink
trivial optimization
Browse files Browse the repository at this point in the history
  • Loading branch information
ADmad committed Feb 12, 2013
1 parent 213e81b commit 1b22d48
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/Cake/Log/Engine/FileLog.php
Expand Up @@ -59,7 +59,7 @@ public function __construct($config = array()) {
$config = $this->config($config);
$this->_path = $config['path'];
$this->_file = $config['file'];
if (!empty($this->_file) && !preg_match('/\.log$/', $this->_file)) {
if (!empty($this->_file) && substr($this->_file, -4) !== '.log') {
$this->_file .= '.log';
}
}
Expand Down

0 comments on commit 1b22d48

Please sign in to comment.