         user.room = null
         console.log "msg <#{from}> #{message}"
 
-      self.receive new Robot.TextMessage(user, message)
+      self.receive new TextMessage(user, message)
 
     bot.addListener 'error', (message) ->
         console.error('ERROR: %s: %s', message.command, message.args.join(' '))

Robot   = require('hubot').robot()
Adapter = require('hubot').adapter()

Irc     = require 'irc'

class IrcBot extends Adapter
  constructor: (@robot) ->
    super @robot

    @robot.notice = (user, strings...) ->
      @adapter.notice user, strings...

    @robot.Response = IrcResponse

  send: (user, strings...) ->
    for str in strings
      if not str?


    self.emit "connected"

class IrcResponse extends Response
  notice: (strings...) ->
    @robot.adapter.notice @message.user, strings...

