# File lib/thinking_sphinx/middlewares/utf8.rb, line 4 def call(contexts) contexts.each do |context| context[:results].each { |row| update_row row } update_row context[:meta] end unless ThinkingSphinx::Configuration.instance.settings['utf8'] app.call contexts end
# File lib/thinking_sphinx/middlewares/utf8.rb, line 15 def update_row(row) row.each do |key, value| next unless value.is_a?(String) row[key] = ThinkingSphinx::UTF8.encode value end end