Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
# app/controllers/application_controller.rb
def add_message(type, text)
@messages ||= []
@messages.push({type: type, text: text})
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.