Package Data | |
---|---|
Maintainer Username: | jrseliga |
Maintainer Contact: | jseliga@agilesdesign.com (Justin Seliga) |
Package Create Date: | 2016-11-29 |
Package Last Update: | 2017-01-05 |
Language: | PHP |
License: | MIT |
Last Refreshed: | 2024-11-23 03:24:46 |
Package Statistics | |
---|---|
Total Downloads: | 18 |
Monthly Downloads: | 0 |
Daily Downloads: | 0 |
Total Stars: | 2 |
Total Watchers: | 1 |
Total Forks: | 0 |
Total Open Issues: | 0 |
Custom Exception Handling for Laravel
composer require agilesdesign/exceptum
'providers' => [
Exceptum\Providers\ExceptumServiceProvider::class,
];
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
}
}
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);
}