diff options
author | Frédéric Guillot <fred@kanboard.net> | 2018-03-05 12:04:28 -0800 |
---|---|---|
committer | Frédéric Guillot <fred@kanboard.net> | 2018-03-05 12:04:28 -0800 |
commit | 299198f7181fccf1e9a684649d173a1ebbdfbd1e (patch) | |
tree | c2539efcfae3b193603bbff22dde8b84fd7f9981 /app/Core/Log/Stdout.php | |
parent | a991758e98fc614d35ec67ec904c78fa0ff6feeb (diff) |
Move SimpleLogger lib into app source tree
Diffstat (limited to 'app/Core/Log/Stdout.php')
-rw-r--r-- | app/Core/Log/Stdout.php | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/app/Core/Log/Stdout.php b/app/Core/Log/Stdout.php new file mode 100644 index 00000000..99140801 --- /dev/null +++ b/app/Core/Log/Stdout.php @@ -0,0 +1,25 @@ +<?php + +namespace Kanboard\Core\Log; + +/** + * Stdout logger + * + * @package Kanboard\Core\Log + * @author Frédéric Guillot + */ +class Stdout extends Base +{ + /** + * Logs with an arbitrary level. + * + * @param mixed $level + * @param string $message + * @param array $context + * @return null + */ + public function log($level, $message, array $context = array()) + { + file_put_contents('php://stdout', $this->formatMessage($level, $message, $context), FILE_APPEND); + } +} |