Created
February 20, 2016 22:56
-
-
Save jbenner-radham/a60c8579f9cf70f017de to your computer and use it in GitHub Desktop.
This file contains hidden or 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 | |
/** | |
* Render an exception into an HTTP response. | |
* | |
* @param \Illuminate\Http\Request $request | |
* @param \Exception $e | |
* @return \Illuminate\Http\Response | |
*/ | |
public function render($request, Exception $e) | |
{ | |
if (config('app.debug') && $request->wantsJson()) { | |
return self::renderJson($e); | |
} | |
return parent::render($request, $e); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment