def check_campfire_authentication(&callback)
      # invalid user only returns a nil result!
      campfire.user("me") do |user|
        if user.name
          yield
        else
          command_reply :notice, "AUTH", "could not connect to campfire: invalid API key"
          shutdown
        end
      end
    rescue Firering::Connection::HTTPError => e
      command_reply :notice, "AUTH", "could not connect to campfire: #{e.message}"
      shutdown
    end
def check_campfire_authentication(&callback)
      # invalid user only returns a nil result!
      campfire.user("me") do |user|
        if user.name
          yield
        else
          command_reply :notice, "AUTH", "could not connect to campfire: invalid API key"
          shutdown
        end
      end
    rescue Firering::Connection::HTTPError => e
      command_reply :notice, "AUTH", "could not connect to campfire: #{e.message}"
      shutdown
    end
Checks that the campfire authentication is successful.

 callback - a block to call if successful.

 Yields to the callback on success (async)

 If it fails, it replies with an error to the client and
 disconnects.