 
   # Posts a request to the Akismet API server.
   postRequest: (host, path, query, callback) ->
-    query = qs.stringgify query
+    query = qs.stringify query
+ 
+    if @debug
+      util.log 'Sending request: ' + host + ':' + @port
+      util.log 'Request body: ' + query
 
     client = http.createClient @port, host
     req = client.request 'POST', path, {

http = require 'http'
qs = require 'querystring'


class Akismet

    req.end()

    req.on 'response', (res) ->
      if @debug
        util.log 'Response: ' + util.inspect res
      res.setEncoding 'utf-8'
      res.on 'data', (body) ->
        callback res.statusCode, res.headers, body
