<commit_before>// Place your application-specific JavaScript functions and classes here
// This file is automatically included by javascript_include_tag :defaults
jQuery(document).ready(function(){

	if(typeof(ToggleSideMenu) != "undefined"){
		ToggleSideMenu();
	}

	// Add authentication to AJAX POSTs made by jQuery 
	jQuery(document).ajaxSend(function(event, request, settings) {
		if (settings.type == 'GET') return;
		if (typeof(AUTH_TOKEN) == "undefined") return;
		settings.data = settings.data || "";
		// This was removed to prevent a bug in the search result pagination in Chrome, but
		// should be uncommented if any issue with AUTH_TOKEN arise.
		//settings.data += (settings.data ? "&" : "") + "authenticity_token=" + encodeURIComponent(AUTH_TOKEN);
	});
})


jQuery.ajaxSetup({ 
  'beforeSend': function(xhr) {xhr.setRequestHeader("Accept", "text/javascript")}
})<commit_msg>Implementing automatic appending of AUTH_TOKEN in ajax requests for IE only<commit_after>// Place your application-specific JavaScript functions and classes here
// This file is automatically included by javascript_include_tag :defaults
jQuery(document).ready(function(){

	if(typeof(ToggleSideMenu) != "undefined"){
		ToggleSideMenu();
	}

	// Add authentication to AJAX POSTs made by jQuery 
	jQuery(document).ajaxSend(function(event, request, settings) {
		if (settings.type == 'GET') return;
		if (typeof(AUTH_TOKEN) == "undefined") return;
		settings.data = settings.data || "";
		if(jQuery.browser.msie){
			settings.data += (settings.data ? "&" : "") + "authenticity_token=" + encodeURIComponent(AUTH_TOKEN);
		}
	});
})


jQuery.ajaxSetup({ 
  'beforeSend': function(xhr) {xhr.setRequestHeader("Accept", "text/javascript")}
})
{'fraction_non_alphanumeric': 0.13797101449275362, 'fraction_numerical': 0.0, 'mean_word_length': 5.231046931407942, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '7638978', 'n_tokens_mistral': 525, 'n_tokens_neox': 497, 'n_words': 137}