mirror of
https://github.com/Seldaek/monolog.git
synced 2025-08-05 20:57:36 +02:00
Merge branch '1.x'
This commit is contained in:
@@ -92,7 +92,7 @@ class NewRelicHandler extends AbstractProcessingHandler
|
||||
newrelic_notice_error($record['message']);
|
||||
}
|
||||
|
||||
if (isset($record['formatted']['context'])) {
|
||||
if (isset($record['formatted']['context']) && is_array($record['formatted']['context'])) {
|
||||
foreach ($record['formatted']['context'] as $key => $parameter) {
|
||||
if (is_array($parameter) && $this->explodeArrays) {
|
||||
foreach ($parameter as $paramKey => $paramValue) {
|
||||
@@ -104,7 +104,7 @@ class NewRelicHandler extends AbstractProcessingHandler
|
||||
}
|
||||
}
|
||||
|
||||
if (isset($record['formatted']['extra'])) {
|
||||
if (isset($record['formatted']['extra']) && is_array($record['formatted']['extra'])) {
|
||||
foreach ($record['formatted']['extra'] as $key => $parameter) {
|
||||
if (is_array($parameter) && $this->explodeArrays) {
|
||||
foreach ($parameter as $paramKey => $paramValue) {
|
||||
|
@@ -81,7 +81,7 @@ class StreamHandler extends AbstractProcessingHandler
|
||||
protected function write(array $record)
|
||||
{
|
||||
if (!is_resource($this->stream)) {
|
||||
if (!$this->url) {
|
||||
if (null === $this->url || '' === $this->url) {
|
||||
throw new \LogicException('Missing stream url, the stream can not be opened. This may be caused by a premature call to close().');
|
||||
}
|
||||
$this->createDir();
|
||||
|
Reference in New Issue
Block a user