<commit_before>class <%= controller_class_name %>Controller < InheritedResources::Base
<% if options[:singleton] -%>
  defaults :singleton => true
<% end -%>
end<commit_msg>change controller scaffold template in order to build resource params<commit_after>class <%= controller_class_name %>Controller < InheritedResources::Base
<% if options[:singleton] -%>
  defaults :singleton => true
<% end -%>

private

  def <%= singular_name %>_params
    params.fetch(:<%= singular_name %>, {}).permit(<%= attributes_names.map{ |a_name| ":#{a_name}" }.join(", ") %>)
  end

end

{'fraction_non_alphanumeric': 0.16842105263157894, 'fraction_numerical': 0.0, 'mean_word_length': 5.7976190476190474, 'pattern_counts': {'":': 1, '<': 14, '<?xml version=': 0, '>': 14, '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': '5097900', 'n_tokens_mistral': 192, 'n_tokens_neox': 174, 'n_words': 42}