module CrystalFlashMessages::Helpers

Public Instance Methods

crystal_flash_messages(options = {}) click to toggle source
# File lib/crystal_flash_messages/helpers.rb, line 5
def crystal_flash_messages(options = {})
  return '' if flash.empty?
  private_helpers = CrystalFlashMessages::PrivateHelpers

  config = private_helpers.local_config(options)
  flash.map do |key, message|
    private_helpers.wrapper(key.to_s, message, config)
  end.join.html_safe
end