agilesdesign / exceptum
Custom Exception Handling for Laravel
Installs: 18
Dependents: 0
Suggesters: 0
Security: 0
Stars: 2
Watchers: 0
Forks: 0
Open Issues: 0
pkg:composer/agilesdesign/exceptum
This package is auto-updated.
Last update: 2025-10-23 00:53:39 UTC
README
Custom Exception Handling for Laravel
Installation
Include through composer
composer require agilesdesign/exceptum
Add to provider list
'providers' => [ Exceptum\Providers\ExceptumServiceProvider::class, ];
Usage
Create an Abettor
Abettor is synonymous with App\Exceptions\Handler in it's intent, but is not an extension of it.
Currently it only supports implementing the response provided to the render method on App\Exception\Handler
class AuthorizatonExceptionAbettor implements Abettor
{
public function render($request, Exception $exception)
{
// handle exception
}
}
Register Mapping
Exceptum falls back to Laravel's App\Exception\Handler class unless it knows about an Abettor responsible for Exception thrown.
To tell Exceptum about an Abettor register a mapping in your ServiceProviders register method
public function register() { Exceptum::map(AuthorizationException::class, AuthorizationExceptionAbettor::class); }