mirror of
https://github.com/danog/MadelineProto.git
synced 2024-11-30 06:59:01 +01:00
Improve logging
This commit is contained in:
parent
ed68a88598
commit
3d4813eb02
@ -123,12 +123,12 @@ class Logger
|
||||
|
||||
public static function log($param, $level = self::NOTICE)
|
||||
{
|
||||
if ($level > self::$level || self::$mode === 0) {
|
||||
return false;
|
||||
}
|
||||
if (self::$mode === 4) {
|
||||
return call_user_func_array(self::$optional, [$param, $level]);
|
||||
}
|
||||
if ($level > self::$level) {
|
||||
return false;
|
||||
}
|
||||
$prefix = self::$prefix;
|
||||
if (\danog\MadelineProto\Logger::$has_thread && is_object(\Thread::getCurrentThread())) {
|
||||
$prefix .= ' (t)';
|
||||
|
Loading…
Reference in New Issue
Block a user