We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 5f42920 + 736dcd5 commit e63701dCopy full SHA for e63701d
src/Middleware/OAuthExceptionHandlerMiddleware.php
@@ -33,7 +33,13 @@ class OAuthExceptionHandlerMiddleware
33
public function handle($request, Closure $next)
34
{
35
try {
36
- return $next($request);
+ $response = $next($request);
37
+ // Was an exception thrown? If so and available catch in our middleware
38
+ if (isset($response->exception) && $response->exception) {
39
+ throw $response->exception;
40
+ }
41
+
42
+ return $response;
43
} catch (OAuthException $e) {
44
$data = [
45
'error' => $e->errorType,
0 commit comments