Skip to content

Commit

Permalink
#165 - add sentry (#166)
Browse files Browse the repository at this point in the history
- add sentry integration
  • Loading branch information
Blusia authored Oct 21, 2024
1 parent fd43639 commit 1c38cca
Show file tree
Hide file tree
Showing 4 changed files with 487 additions and 84 deletions.
3 changes: 3 additions & 0 deletions bootstrap/app.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
use Illuminate\Http\Request;
use Inertia\Inertia;
use Keating\Http\Middleware\HandleInertiaRequests;
use Sentry\Laravel\Integration;
use Symfony\Component\HttpFoundation\Response;

return Application::configure(basePath: dirname(__DIR__))
Expand All @@ -23,6 +24,8 @@
$middleware->trustProxies("*");
})
->withExceptions(function (Exceptions $exceptions): void {
Integration::handles($exceptions);

$exceptions->respond(function (Response $response, Throwable $exception, Request $request) {
if (!app()->environment("production")) {
return $response;
Expand Down
1 change: 1 addition & 0 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
"laravel/framework": "^11.25.0",
"laravel/sanctum": "^4.0.2",
"laravel/tinker": "^2.10.0",
"sentry/sentry-laravel": "^4.9",
"spatie/laravel-options": "^1.1.1",
"stevebauman/purify": "^6.2.2"
},
Expand Down
Loading

0 comments on commit 1c38cca

Please sign in to comment.