Skip to content

Commit 03d3f29

Browse files
committed
Disable sentry's default integrations when using it
Monolog already does it, so...
1 parent fabf119 commit 03d3f29

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

DependencyInjection/MonologExtension.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -681,7 +681,10 @@ private function buildHandler(ContainerBuilder $container, $name, array $handler
681681
} else {
682682
$options = new Definition(
683683
'Sentry\\Options',
684-
[['dsn' => $handler['dsn']]]
684+
[[
685+
'dsn' => $handler['dsn'],
686+
'default_integrations' => false, // prevent sentry from registering shutdown functions
687+
]]
685688
);
686689

687690
if (!empty($handler['environment'])) {
@@ -710,9 +713,6 @@ private function buildHandler(ContainerBuilder $container, $name, array $handler
710713
[new Reference($clientId)]
711714
);
712715

713-
// can't set the hub to the current hub, getting into a recursion otherwise...
714-
//$hub->addMethodCall('setCurrent', array($hub));
715-
716716
$definition->setArguments([
717717
$hub,
718718
$handler['level'],

0 commit comments

Comments
 (0)