Last active
April 8, 2020 19:43
-
-
Save acidjazz/7527d5e86a6f648b9cfde518042b4f55 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
if (app()->bound('sentry') && $this->shouldReport($exception)) { | |
$sentry = app('sentry'); | |
if (auth()->check()) { | |
\Sentry\configureScope(function (\Sentry\State\Scope $scope): void { | |
$scope->setUser([ | |
'id' => auth()->user()->id, | |
'name' => auth()->user()->fullname, | |
'email' => auth()->user()->email, | |
]); | |
$scope->setTag('service', config('app.name')); | |
$scope->setExtra('service', config('app.name')); | |
}); | |
} | |
$sentry->captureException($exception); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment