       @addListener document, "click", (event) =>
         target = event.target
         if target
+          @log("Checking if click event should be rendered")
           aTag = @findATag(target)
-          if aTag && @leftMouseButton(event) && !@metakeyPressed(event) && @targetAttributeIsCurrentWindow(aTag) && @targetHostSame(aTag)
+          if @blog("- A tag", aTag) &&
+          @blog("- Left mouse button click", @leftMouseButton(event)) &&
+          @blog("- Not meta keys pressed", !@metakeyPressed(event)) &&
+          @blog("- Target attribute is current window", @targetAttributeIsCurrentWindow(aTag)) &&
+          @blog("- Link host same as current window", @targetHostSame(aTag))
             href = aTag.attributes.href.nodeValue
-            @log("Processing click", href)
+            @log("Click event passed all checks, rendering ", href)
             if !@pushStateSupport && @hashchangeSupport && @hashBaseUrl && @hashBaseUrl != window.location.pathname
+              @log("Using hashbang change to trigger rendering")
               event.preventDefault();
               window.location.href = @hashBaseUrl + "#!" + href
               return

  postExecutionListeners: []
  debug: false
  log: =>
    if @debug
      console.log.apply(this, arguments)
  add: (urlPattern, fn, metadata) =>
    @routes.push({route: new SinatraRouteParser(urlPattern), fn: fn, urlPattern: urlPattern, metadata: metadata})
  exec: (path) =>

              event.preventDefault();
              @updateUrl(href)

  blog: (str, v) =>
    @log(str + ", result: " + v)
    v

  leftMouseButton: (event) =>
    event.which? && event.which == 1 || event.button == 0

