 
       robot.messageRoom room, message
     .catch ( error ) ->
-      console.log "Error: #{error}"
+      console.log error.stack
 
   robot.respond /(?:github|gh|git) delete all notifications/i, (msg) ->
     notificationsCleared = clearAllNotificationsForRoom(findRoom(msg))

    robot.brain.set 'github-notifications', notifications

  lookupUserWithGithub = (github) ->
    if github
      users = robot.brain.users()
      users = _(users).keys().map (id) ->
        u = users[id]

      return

    repo = octo.repos(githubOrg, repo)
    repo.pulls.fetch(state: "open")
    .then (prs) ->
      return Promise.all prs.map (pr) ->
        if user?
          return if not pr.assignee?
          return lookupUserWithGithub(pr.assignee).then (assignee) ->
            return if user.toLowerCase() isnt assignee?.name.toLowerCase()
            return repo.pulls(pr.number).fetch()
        else
          return repo.pulls(pr.number).fetch()
    .then (prs) ->
      return Promise.all prs.map (pr) ->
        return if not pr
        author = lookupUserWithGithub pr.user
        assignee = lookupUserWithGithub pr.assignee
        return Promise.all [ pr, author, assignee ]
    .then (prs) ->
      message = ""
      for p in prs when p
        pr = p[0]
        author = p[1]
        assignee = p[2]
        message+= """
          *[#{pr.title}]* +#{pr.additions} -#{pr.deletions}
          #{pr.htmlUrl}
