File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
src/Sentry/Laravel/Integration Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change 2
2
3
3
namespace Sentry \Laravel \Integration ;
4
4
5
- use Illuminate \Support \ Facades \ Context ;
5
+ use Illuminate \Log \ Context \ Repository as ContextRepository ;
6
6
use Sentry \Event ;
7
7
use Sentry \EventHint ;
8
8
use Sentry \EventType ;
@@ -15,7 +15,7 @@ class LaravelContextIntegration implements IntegrationInterface
15
15
public function setupOnce (): void
16
16
{
17
17
// Context was introduced in Laravel 11 so we need to check if we can use it otherwise we skip the event processor
18
- if (!class_exists (Context ::class)) {
18
+ if (!class_exists (ContextRepository ::class)) {
19
19
return ;
20
20
}
21
21
@@ -30,7 +30,7 @@ public function setupOnce(): void
30
30
return $ event ;
31
31
}
32
32
33
- $ event ->setContext ('laravel ' , Context:: all ());
33
+ $ event ->setContext ('laravel ' , app (ContextRepository::class)-> all ());
34
34
35
35
return $ event ;
36
36
});
You can’t perform that action at this time.
0 commit comments