| Total Complexity | 7 |
| Total Lines | 51 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 0 | ||
| 1 | <?php |
||
| 26 | } |
||
| 27 | |||
| 28 | /** |
||
| 29 | * Helper method to get inherited roles for given roles. |
||
| 30 | * |
||
| 31 | * @param array<int, string> $roles |
||
| 32 | * |
||
| 33 | * @return array<int, string> |
||
| 34 | */ |
||
| 35 | public function getInheritedRoles(array $roles): array |
||
| 36 | { |
||
| 37 | return array_values(array_unique($this->roleHierarchy->getReachableRoleNames($roles))); |
||
| 38 | } |
||
| 39 | } |
||
| 40 |