mirror of
https://github.com/Seldaek/monolog.git
synced 2025-10-22 00:56:08 +02:00
Merge branch '1.x'
This commit is contained in:
@@ -157,6 +157,19 @@ class Logger implements LoggerInterface
|
||||
return $this->name;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return a new cloned instance with the name changed
|
||||
*
|
||||
* @return static
|
||||
*/
|
||||
public function withName($name)
|
||||
{
|
||||
$new = clone $this;
|
||||
$new->name = $name;
|
||||
|
||||
return $new;
|
||||
}
|
||||
|
||||
/**
|
||||
* Pushes a handler on to the stack.
|
||||
*
|
||||
|
Reference in New Issue
Block a user