protected function formatLabelNames(array $labels)
    {
        if (empty($labels)) {
            return;
        }
        $names = [];

        foreach ($labels as $label) {
            if (!isset($label['name'])) {
                continue;
            }
            $names[] = $label['name'];
        }

        return implode(', ', $names);
    }