<commit_before>class Opendata::Agents::Nodes::ApiController < ApplicationController
  include Cms::NodeFilter::View
  include Opendata::MypageFilter

  before_action :accept_cors_request
  skip_filter :logged_in?

  public

    def index
      render
    end

    def package_list

      #@items = Opendata::Dataset.site(@cur_site).member(@cur_member).order_by(updated: -1)
      @items = Opendata::Dataset.site(@cur_site).order_by(filename: 1)

      render :json => @items.to_json
    end

end<commit_msg>fix: package_list<commit_after>class Opendata::Agents::Nodes::ApiController < ApplicationController
  include Cms::NodeFilter::View

  before_action :accept_cors_request

  public

    def index
      render
    end

    def package_list

      @items = Opendata::Dataset.site(@cur_site).public.order_by(name: 1)

      package_list = []
      @items.each do |item|
        package_list << item[:name]
      end

      res = {
        help: "Package List",
        success: true,
        result: package_list,
      }

      render json: res
    end

end
{'fraction_non_alphanumeric': 0.10084825636192271, 'fraction_numerical': 0.002827521206409048, 'mean_word_length': 3.132295719844358, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 4, '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': '6267992', 'n_tokens_mistral': 346, 'n_tokens_neox': 332, 'n_words': 66}