private function describeRoles(array $roles)
    {
        $withInitials = array_map(function ($role) {
            return sprintf('%s (%s)', $role, substr($role, 0, 1));
        }, $roles);
        $last = array_pop($withInitials);

        return implode(' or ', [implode(', ', $withInitials), $last]);
    }
private function describeRoles(array $roles)
    {
        $withInitials = array_map(function ($role) {
            return sprintf('%s (%s)', $role, substr($role, 0, 1));
        }, $roles);
        $last = array_pop($withInitials);

        return implode(' or ', [implode(', ', $withInitials), $last]);
    }
private function describeRoles ( array $ roles ) { $ withInitials = array_map ( function ( $ role ) { return sprintf ( '%s (%s)' , $ role , substr ( $ role , 0 , 1 ) ) ; } , $ roles ) ; $ last = array_pop ( $ withInitials ) ; return implode ( ' or ' , [ implode ( ', ' , $ withInitials ) , $ last ] ) ; }
Expand roles into a list with abbreviations.

@param string[] $roles

@return string
Expand roles into a list with abbreviations .