Module: UnobtrusiveFlash::ControllerMixin
- Defined in:
- lib/unobtrusive_flash/controller_mixin.rb
Class Method Summary collapse
Class Method Details
.sanitize_flash(flash) ⇒ Object
33 34 35 36 37 38 |
# File 'lib/unobtrusive_flash/controller_mixin.rb', line 33 def sanitize_flash(flash) flash.to_a.map do |key, value| html_safe_value = value.html_safe? ? value : ERB::Util.html_escape(value) [key, html_safe_value] end end |