Created
June 16, 2020 06:05
-
-
Save osibg/be05ba87b052eb4b695950dd51951282 to your computer and use it in GitHub Desktop.
Custom exception with own rendering method
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 | |
namespace App\Exceptions; | |
class RenderException extends \Exception | |
{ | |
public function report() | |
{ | |
// overwrite default report/log behavior | |
} | |
public function render($request) | |
{ | |
return response('...', 500); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment