module ActionDispatch::Flash::RequestMethods

def flash

See ActionDispatch::Flash for example usage.

Access the contents of the flash. Returns a ActionDispatch::Flash::FlashHash.
def flash
  flash = flash_hash
  return flash if flash
  self.flash = Flash::FlashHash.from_session_value(session["flash"])
end