lib/lita/adapters/shell.rb in lita-2.4.0 vs lib/lita/adapters/shell.rb in lita-2.5.0
- old
+ new
@@ -5,11 +5,12 @@
# Creates a "Shell User" and then loops a prompt and input, passing the
# incoming messages to the robot.
# @return [void]
def run
user = User.create(1, name: "Shell User")
- source = Source.new(user)
+ source = Source.new(user: user)
puts 'Type "exit" or "quit" to end the session.'
+ robot.trigger(:connected)
loop do
print "#{robot.name} > "
input = $stdin.gets
if input.nil?