<div class="govuk-!-margin-top-8">
  <%= render "govuk_publishing_components/components/radio", {
    name: "c[]",
    heading: current_question.text,
    description: formatted_description,
    hint_text: current_question.hint_title,
    is_page_heading: true,
    items: current_question.options.map do |option|
      checkboxes = if option.sub_options
                     render "govuk_publishing_components/components/checkboxes", {
                       name: "c[]",
                       heading: option.label,
                       visually_hide_heading: true,
                       items: format_question_options(option.sub_options, criteria_keys)
                     }
                   end

      format_question_option(option, criteria_keys).merge(conditional: checkboxes)
    end
  } %>
</div>

<div class="govuk-!-margin-top-8">
  <%= render "govuk_publishing_components/components/radio", {
    name: "c[]",
    heading: current_question.text,
    description: formatted_description,
    hint_text: current_question.hint_title,
    is_page_heading: true,
    items: current_question.options.map do |option|
      checkboxes = if option.sub_options.present?
                     render "govuk_publishing_components/components/checkboxes", {
                       name: "c[]",
                       heading: option.label,
                       visually_hide_heading: true,
                       items: format_question_options(option.sub_options, criteria_keys)
                     }
                   end

      format_question_option(option, criteria_keys).merge(conditional: checkboxes)
    end
  } %>
</div>

Stop rendering checkboxes for no option
Stop rendering checkboxes for no option
