<commit_before>
steal('jquery/event', 'jquery/event/handle').then(function($){

$.fn.
/**
 * @function jQuery.fn.triggerAsync
 * @plugin jquery/event/default
 * @parent jquery.event.pause
 * 
 * Triggers an event and calls success when the event has finished propagating through the DOM and
 * preventDefault is not called.
 * 
 *     $('#panel').triggerAsync('show', function(){
 *       $('#panel').show();
 *     })
 * 
 * You can also provide a callback that gets called if preventDefault was called on the event:
 * 
 *     $('#panel').triggerAsync('show', function(){
 *       $('#panel').show();
 *     },function(){
 *       $('#other').addClass('error');
 *     })
 * 
 * triggerAsync is designed to work with the [jquery.event.pause] plugin although it is defined in 
 * <code>jquery/event/default</code>
 * 
 * 
 * @param {String} type The type of event
 * @param {Object} data The data for the event
 * @param {Function} success(event) a callback function
 * @param {Function} prevented(event) called if preventDefault is called on the 
 */
triggerAsync = function(type, data, success, prevented){
	if(typeof data == 'function'){
		success = data;
		data = undefined;
	}
	
	if ( this[0] ) {
		var event = $.Event( type ),
			old = event.preventDefault;
		
		event.preventDefault = function(){
			old.apply(this, arguments);
			prevented && prevented(this)
		}
		//event._success= success;
		jQuery.event.trigger( {type: type, _success: success}, data, this[0]  );
	} else{
		success.call(this);
	}
	return this;
}
	<commit_msg>fix for async docs not working<commit_after>
steal('jquery/event', 'jquery/event/handle').then(function($){

/**
 * @function jQuery.fn.triggerAsync
 * @plugin jquery/event/default
 * @parent jquery.event.pause
 * 
 * Triggers an event and calls success when the event has finished propagating through the DOM
 * and preventDefault is not called.
 *
 *     $('#panel').triggerAsync('show', function() {
 *        $('#panel').show();
 *     });
 *
 * You can also provide a callback that gets called if preventDefault was called on the event:
 *
 *     $('panel').triggerAsync('show', function(){
 *         $('#panel').show();
 *     },function(){ 
 *         $('#other').addClass('error');
 *     });
 *
 * triggerAsync is design to work with the [jquery.event.pause] plugin although it is defined in
 * <code>jquery/event/default</code>
 * 
 * @param {String} type The type of event
 * @param {Object} data The data for the event
 * @param {Function} success(event) a callback function which occurs upon success
 * @param {Function} prevented(event) a callback function which occurs if preventDefault was called
 */
$.fn.triggerAsync = function(type, data, success, prevented){
	if(typeof data == 'function'){
		success = data;
		data = undefined;
	}
	
	if ( this[0] ) {
		var event = $.Event( type ),
			old = event.preventDefault;
		
		event.preventDefault = function(){
			old.apply(this, arguments);
			prevented && prevented(this)
		}
		//event._success= success;
		jQuery.event.trigger( {type: type, _success: success}, data, this[0]  );
	} else{
		success.call(this);
	}
	return this;
}
	
{'fraction_non_alphanumeric': 0.15114795918367346, 'fraction_numerical': 0.0012755102040816326, 'mean_word_length': 3.5929721815519766, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3481076', 'n_tokens_mistral': 956, 'n_tokens_neox': 912, 'n_words': 288}