<commit_before>module RubygemsHelper
  def formatted_licenses(license_names)
    if license_names.blank?
      t(".no_licenses")
    else
      Array(license_names).join ", "
    end
  end

  def link_to_page(text, url)
    link_to(text, url, :rel => 'nofollow', :class => ['gem__link', 't-list__item']) if url.present?
  end

  def link_to_directory
    ("A".."Z").map { |letter| link_to(letter, rubygems_path(:letter => letter)) }.join
  end

  def simple_markup(text)
    if text =~ /^==+ [A-Z]/
      RDoc::Markup.new.convert(text, RDoc::Markup::ToHtml.new).html_safe
    else
      content_tag :p, escape_once(sanitize(text).strip.html_safe), nil, false
    end
  end

  def subscribe_link(rubygem)
    if signed_in?
      subscribe = link_to 'Subscribe', rubygem_subscription_path(rubygem),
        :remote => true,
        :method => :post,
        :id     => 'subscribe',<commit_msg>Fix locale .no_licenses path<commit_after>module RubygemsHelper
  def formatted_licenses(license_names)
    if license_names.blank?
      t("rubygems.show.no_licenses")
    else
      Array(license_names).join ", "
    end
  end

  def link_to_page(text, url)
    link_to(text, url, :rel => 'nofollow', :class => ['gem__link', 't-list__item']) if url.present?
  end

  def link_to_directory
    ("A".."Z").map { |letter| link_to(letter, rubygems_path(:letter => letter)) }.join
  end

  def simple_markup(text)
    if text =~ /^==+ [A-Z]/
      RDoc::Markup.new.convert(text, RDoc::Markup::ToHtml.new).html_safe
    else
      content_tag :p, escape_once(sanitize(text).strip.html_safe), nil, false
    end
  end

  def subscribe_link(rubygem)
    if signed_in?
      subscribe = link_to 'Subscribe', rubygem_subscription_path(rubygem),
        :remote => true,
        :method => :post,
        :id     => 'subscribe',
{'fraction_non_alphanumeric': 0.1414364640883978, 'fraction_numerical': 0.0, 'mean_word_length': 3.3119047619047617, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 15, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '945522', 'n_tokens_mistral': 651, 'n_tokens_neox': 636, 'n_words': 126}