Skip to content

Commit

Permalink
Merge pull request #3398 from acrobat/fix-monolog-bridge-deprecation
Browse files Browse the repository at this point in the history
[AdminBundle] Fix monolog-bridge logger deprecation
  • Loading branch information
acrobat authored Apr 11, 2024
2 parents 55c003f + 2a5ed09 commit 06a5357
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 9 deletions.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
"symfony/http-foundation": "^6.4",
"symfony/http-kernel": "^6.4",
"symfony/mailer": "^6.4",
"symfony/monolog-bridge": "^6.4",
"symfony/monolog-bundle": "^3.10",
"symfony/options-resolver": "^6.4",
"symfony/property-access": "^6.4",
"symfony/routing": "^6.4",
Expand Down
5 changes: 3 additions & 2 deletions src/Kunstmaan/AdminBundle/Resources/config/services.yml
Original file line number Diff line number Diff line change
Expand Up @@ -138,8 +138,9 @@ services:
arguments: ['%kernel.logs_dir%/kunstmaan_%kernel.environment%.log', 10]

kunstmaan_admin.logger:
class: Symfony\Bridge\Monolog\Logger
arguments: [kunstmaan]
parent: monolog.logger_prototype
arguments:
index_0: 'kunstmaan'
calls:
- [pushHandler, ['@kunstmaan_admin.logger.handler']]

Expand Down
2 changes: 1 addition & 1 deletion src/Kunstmaan/AdminBundle/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
"symfony/form": "^6.4",
"symfony/http-foundation": "^6.4",
"symfony/http-kernel": "^6.4",
"symfony/monolog-bridge": "^6.4",
"symfony/monolog-bundle": "^3.10",
"symfony/mailer": "^6.4",
"symfony/options-resolver": "^6.4",
"symfony/property-access": "^6.4",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
use Kunstmaan\NodeBundle\Event\Events;
use Kunstmaan\NodeBundle\Event\NodeEvent;
use Kunstmaan\NodeBundle\Event\RecopyPageTranslationNodeEvent;
use Symfony\Bridge\Monolog\Logger;
use Monolog\Logger;
use Symfony\Component\EventDispatcher\EventSubscriberInterface;
use Symfony\Component\Security\Core\Authentication\Token\Storage\TokenStorageInterface;

Expand All @@ -28,10 +28,6 @@ class LogPageEventsSubscriber implements EventSubscriberInterface
*/
private $user;

/**
* @param Logger $logger The logger
* @param TokenStorageInterface $tokenStorage The security token storage
*/
public function __construct(Logger $logger, TokenStorageInterface $tokenStorage)
{
$this->logger = $logger;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,5 @@
new \Kunstmaan\TranslatorBundle\KunstmaanTranslatorBundle(),
new \Symfony\Bundle\AclBundle\AclBundle(),
new \Doctrine\Bundle\DoctrineBundle\DoctrineBundle(),
new \Symfony\Bundle\MonologBundle\MonologBundle(),
];

0 comments on commit 06a5357

Please sign in to comment.