| Conditions | 1 |
| Paths | 1 |
| Total Lines | 8 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 38 | public function finalizeScopes(array $scopes, $grantType, ClientEntityInterface $clientEntity, $userIdentifier = null) |
||
| 39 | { |
||
| 40 | $abilityIds = app('cortex.auth.ability')->all()->pluck('id'); |
||
| 41 | |||
| 42 | return collect($scopes)->filter(function ($scope) use ($abilityIds) { |
||
| 43 | return $abilityIds->contains(app('cortex.auth.ability')->unhashId($scope->getIdentifier())); |
||
| 44 | })->all(); |
||
| 45 | } |
||
| 46 | } |
||
| 47 |
This check looks for the generic type
arrayas a return type and suggests a more specific type. This type is inferred from the actual code.