I would suggest that you are not looking at anything. The Hubot script interface is not well documented, but notify.coffee
in the examples says the following:
module.exports = (robot) -> robot.hear /@(\w+)/i, (msg) -> sender = msg.message.user.name.toLowerCase()
So you probably want to look at msg.message
instead of msg
:
robot.enter (msg) -> msg.send "#{msg.message.user.name}"
source share