     @image.src = @url
     return
 
-  ### Cancel any running request.  The onComplete callback will not be called.
+  # Cancel any running request.  The onComplete callback will not be called.
   # The object must not be reused.
-  ###
-
   destroy: ->
     document.documentElement.removeClassName 'progress'
     @onComplete = null

    @destroy()
    return

  ### When the image finishes loading after form_submit_event sets it, update the canvas
  # thumbnail from it.
  ###

  image_load_event: (e) ->

    ### Reduce the image size to thumbnail resolution. ###

    width = @image.width
    height = @image.height
    max_width = 128

        alert 'The file couldn\'t be loaded.'
      return

    # Grab a data URL from the canvas; this is what we'll send to the server.
    data_url = result.canvas.toDataURL()

    # Create the FormData containing the thumbnail image we're sending.
    form_data = new FormData
    form_data.append 'url', data_url
    req = new (Ajax.Request)('/post/similar.json',
