 
       return unless @dragStarted
 
-      if @config.helper is 'clone'
+      if @getConfig().helper is 'clone'
         # Destroy the helper
         @$helper.remove()
         # Trigger the click event on the original element

    #

    isValidHandle: (element) ->
      if @config.handle
        $element = $(element)

        # Is this element the handle itself, or a descendant of the handle?
        !!$element.closest(@config.handle).length
      else
        # No handle was specified; anything is fair game
        true


    setupElement: ->
      # Position the draggable relative if it's currently statically positioned
      @$element.css(position: 'relative') if @getConfig().helper is 'original' and @$element.css('position') is 'static'

      # Done!
      @setupPerformed = true
