diff --git a/src/scripts.php b/src/scripts.php index b359e98..4f28d20 100644 --- a/src/scripts.php +++ b/src/scripts.php @@ -3,7 +3,7 @@ if (class_exists('Leaf\Config')) { \Leaf\Config::addScript(function () { \Leaf\Config::singleton('logWriter', function ($c) { - is_object($c['log.writer']) ? + return is_object($c['log.writer']) ? $c['log.writer'] : new \Leaf\LogWriter($c['log.dir'] . $c['log.file'], $c['log.open'] ?? true); });