Sha256: dffc4c280fc0ff5b11b7c72b2e3d6113f92d16dd128b53380c9539a19d7bc46a
Contents?: true
Size: 512 Bytes
Versions: 6
Compression:
Stored size: 512 Bytes
Contents
module FlashMessageReporter extend ActiveSupport::Concern included do before_filter :set_flash_message_from_params end private def set_flash_message_from_params return if request.env["HTTP_REFERER"].blank? referer_uri = URI.parse(request.env["HTTP_REFERER"]) return unless referer_uri.host.ends_with?(core_domain) flash[:notice] = params[:flash][:notice] if params[:flash][:notice] flash[:alert] = params[:flash][:alert] if params[:flash][:alert] rescue nil end end
Version data entries
6 entries across 6 versions & 1 rubygems