Skip to content

Authorization and authentication exceptions answer 403 and 401, not 500 - #26

Merged
dskripchenko merged 1 commit into
masterfrom
fix/laravel-auth-exceptions
Oct 27, 2026
Merged

dskripchenko merged 1 commit into
masterfrom
fix/laravel-auth-exceptions

Conversation

@dskripchenko

Copy link
Copy Markdown
Owner

Fixed: AuthorizationException (a policy or gate said no) and AuthenticationException answered 500 — the error handler knew only its own and HTTP exceptions. Now 403 (errorKey: forbidden, the exception's message) and 401 (unauthenticated). Test included; CHANGELOG updated.

🤖 Generated with Claude Code

… and 401, not 500

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@dskripchenko
dskripchenko merged commit 94b0351 into master Oct 27, 2026
7 checks passed
@dskripchenko
dskripchenko deleted the fix/laravel-auth-exceptions branch October 27, 2026 13:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant