Total Complexity | 4 |
Total Lines | 35 |
Duplicated Lines | 0 % |
Coverage | 0% |
Changes | 0 |
1 | <?php |
||
15 | trait RequestJwtTrait |
||
16 | { |
||
17 | /** |
||
18 | * @return string |
||
19 | */ |
||
20 | public function getBearerTokenFromHeader(): string |
||
21 | { |
||
22 | return str_replace('Bearer ', '', $this->getHeader('Authorization')); |
||
23 | } |
||
24 | |||
25 | /** |
||
26 | * @return bool |
||
27 | */ |
||
28 | public function isEmptyBearerToken(): bool |
||
29 | { |
||
30 | return empty($this->getBearerTokenFromHeader()); |
||
31 | } |
||
32 | |||
33 | /** |
||
34 | * Did we specify we dont need to validate JWT Token on this section? |
||
35 | * |
||
36 | * @return bool |
||
37 | */ |
||
38 | public function ignoreJwt(Route $route) : bool |
||
47 | } |
||
48 | |||
49 | abstract public function getHeader($header); |
||
50 | } |
||
51 |
The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g.
excluded_paths: ["lib/*"]
, you can move it to the dependency path list as follows:For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths