<commit_before>class Cms::Apis::CategoriesController < ApplicationController
  include Cms::ApiFilter

  model Cms::Node

  def index
    @items = @model.site(@cur_site).
      where(route: /^(category\/|opendata\/category)/).
      search(params[:s]).
      order_by(filename: 1).
      page(params[:page]).per(50)
  end
end
<commit_msg>[fix] cms_apis_categories multi selection (#1306)<commit_after>class Cms::Apis::CategoriesController < ApplicationController
  include Cms::ApiFilter

  model Cms::Node

  def index
    @single = params[:single].present?
    @multi = !@single

    @items = @model.site(@cur_site).
      where(route: /^(category\/|opendata\/category)/).
      search(params[:s]).
      order_by(filename: 1).
      page(params[:page]).per(50)
  end
end

{'fraction_non_alphanumeric': 0.15503875968992248, 'fraction_numerical': 0.012919896640826873, 'mean_word_length': 3.754601226993865, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, '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': '2552491', 'n_tokens_mistral': 263, 'n_tokens_neox': 245, 'n_words': 46}