Skip to content

Commit 6fde980

Browse files
committed
fix
1 parent b31119e commit 6fde980

File tree

2 files changed

+32
-0
lines changed

2 files changed

+32
-0
lines changed
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
namespace ErrorHeroModule\Compat;
6+
7+
class LoggerAbstractServiceFactory extends LoggerServiceFactory
8+
{
9+
}
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
namespace ErrorHeroModule\Compat;
6+
7+
use Psr\Container\ContainerInterface;
8+
9+
class LoggerServiceFactory extends \Laminas\Log\LoggerServiceFactory
10+
{
11+
/**
12+
* @{inheritDoc}
13+
*/
14+
public function __invoke(ContainerInterface $container, $requestedName, ?array $options = null)
15+
{
16+
$config = $container->get('config');
17+
$logConfig = $config['log'] ?? [];
18+
19+
$this->processConfig($logConfig, $container);
20+
21+
return new Logger($logConfig);
22+
}
23+
}

0 commit comments

Comments
 (0)