Class: ApplicationHandler

Inherits:
Bot::Handler show all
Defined in:
lib/generators/bot/install/templates/application_handler.rb

Instance Method Summary collapse

Methods inherited from Bot::Handler

#execute_chain, handle, #handle, #responder_chain, responder_chain, use

Instance Method Details

#user_for(message) ⇒ Object



7
8
9
# File 'lib/generators/bot/install/templates/application_handler.rb', line 7

def user_for(message)
  User.find_or_create_by(username: message["from"])
end