mirror of
https://github.com/Seldaek/monolog.git
synced 2025-08-01 10:50:21 +02:00
Merge remote-tracking branch 'arturgspb/master'
This commit is contained in:
@@ -28,9 +28,12 @@ class IntrospectionProcessor
|
|||||||
{
|
{
|
||||||
private $level;
|
private $level;
|
||||||
|
|
||||||
public function __construct($level = Logger::DEBUG)
|
private $skipClassesPartials;
|
||||||
|
|
||||||
|
public function __construct($level = Logger::DEBUG, array $skipClassesPartials = array('Monolog\\'))
|
||||||
{
|
{
|
||||||
$this->level = $level;
|
$this->level = $level;
|
||||||
|
$this->skipClassesPartials = $skipClassesPartials;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -52,9 +55,19 @@ class IntrospectionProcessor
|
|||||||
array_shift($trace);
|
array_shift($trace);
|
||||||
|
|
||||||
$i = 0;
|
$i = 0;
|
||||||
while (isset($trace[$i]['class']) && false !== strpos($trace[$i]['class'], 'Monolog\\')) {
|
|
||||||
$i++;
|
while (isset($trace[$i]['class']))
|
||||||
}
|
{
|
||||||
|
foreach ($this->skipClassesPartials as $part)
|
||||||
|
{
|
||||||
|
if (strpos($trace[$i]['class'], $part) !== false)
|
||||||
|
{
|
||||||
|
$i++;
|
||||||
|
continue 2;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
// we should have the call source now
|
// we should have the call source now
|
||||||
$record['extra'] = array_merge(
|
$record['extra'] = array_merge(
|
||||||
|
Reference in New Issue
Block a user