Conditions | 2 |
Paths | 3 |
Total Lines | 10 |
Code Lines | 6 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php namespace Nord\Lumen\OAuth2\Middleware; |
||
21 | public function handle($request, \Closure $next) |
||
22 | { |
||
23 | try { |
||
24 | $this->getOAuth2Service()->validateAccessToken(); |
||
25 | |||
26 | return $next($request); |
||
27 | } catch (OAuthException $e) { |
||
28 | return $this->accessDeniedResponse('ERROR.ACCESS_DENIED'); |
||
29 | } |
||
30 | } |
||
31 | } |
||
32 |