<commit_before>/**
 * AJAX request abstration
 *
 * @author <NAME>
 * @author <NAME>
 */

require! {
	\jquery : $
	\backbone.wreqr : W
	'./config.json' : config
}

module.exports = (options)->
	options = {
		url: config.ajax_data_url
		data-type: \json
		method: \POST
		cache: false
		error: (xhr, status, err)!->
			W.radio.commands .execute \police, \panic, err
	} <<<< options

	$ .ajax options<commit_msg>fixed bug with aborted ajax in admin front-end<commit_after>/**
 * AJAX request abstration
 *
 * @author <NAME>
 * @author <NAME>
 */

require! {
	\jquery : $
	\backbone.wreqr : W
	'./config.json' : config
}

module.exports = (options)->
	options = {
		url: config.ajax_data_url
		data-type: \json
		method: \POST
		cache: false
		error: (xhr, status, err)!->
			return if status is \abort
			W.radio.commands .execute \police, \panic, err
	} <<<< options

	$ .ajax options
{'fraction_non_alphanumeric': 0.16308040770101925, 'fraction_numerical': 0.0, 'mean_word_length': 3.018181818181818, 'pattern_counts': {'":': 0, '<': 15, '<?xml version=': 0, '>': 11, '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': '5703753', 'n_tokens_mistral': 352, 'n_tokens_neox': 327, 'n_words': 85}