Update Docs

This commit is contained in:
Daniel Mason 2018-06-22 20:13:16 +12:00
parent c906d1ed08
commit f69330d637
6 changed files with 15 additions and 9 deletions

View file

@ -28,6 +28,10 @@ class Resque_Log extends Psr\Log\AbstractLogger
public function log($level, $message, array $context = [])
{
$logLevels = ["emergency", "alert", "critical", "error", "warning", "notice", "info", "debug"];
/**
* Only log things with a higher rating than the current log level.
* e.g If set as 'alert' will only alert for 'emergency' and 'alert' logs.
*/
if (array_search($level, $logLevels) <= array_search($this->logLevel, $logLevels)) {
fwrite(
STDOUT,