(($) -> $.fn.preventDoubleSubmit = () -> $(@).submit -> self = $(@) if @beenSubmitted false else $('fieldset.buttons input', self).attr('disabled', true) @beenSubmitted = true )(jQuery)