Module: Rawbotz::Helpers::FlashHelper

Defined in:
lib/rawbotz/helpers/flash_helper.rb

Instance Method Summary collapse

Instance Method Details

#add_flash(kind, msg) ⇒ Object



7
8
9
10
# File 'lib/rawbotz/helpers/flash_helper.rb', line 7

def add_flash kind, msg
  session[:flash] ||= {}
  (session[:flash][kind] ||= []) << msg
end

#flashObject



4
5
6
# File 'lib/rawbotz/helpers/flash_helper.rb', line 4

def flash
  @flash = session[:flash]# || {}
end