Skip to content

Commit

Permalink
Merge pull request #326 from epipheus/sanitize-disambiguation
Browse files Browse the repository at this point in the history
sanitize(data) disabiguation
  • Loading branch information
Nicolas Rodriguez authored May 8, 2019
2 parents 2a0877f + c022c0f commit f18129d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions lib/ajax-datatables-rails/base.rb
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ def as_json(*)
{
recordsTotal: records_total_count,
recordsFiltered: records_filtered_count,
data: sanitize(data),
data: sanitize_data(data),
}.merge(get_additional_data)
end

Expand Down Expand Up @@ -81,7 +81,7 @@ def get_additional_data
end
end

def sanitize(data)
def sanitize_data(data)
data.map do |record|
if record.is_a?(Array)
record.map { |td| ERB::Util.html_escape(td) }
Expand Down
2 changes: 1 addition & 1 deletion lib/ajax-datatables-rails/version.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# frozen_string_literal: true

module AjaxDatatablesRails
VERSION = '1.0.0'
VERSION = '1.0.1'
end

0 comments on commit f18129d

Please # to comment.