<commit_before>VISH.EventsNotifier = (function(V,$,undefined){

	var listeners;
	// listeners['event'] = [callback1,callback2,...,callbackn];

	var init = function() {
		listeners = new Array();		
	};

	var registerCallback = function(listenedEvent,callback){
		if(listenedEvent in listeners){
			listeners[listenedEvent].push(callback);
		} else {
			listeners[listenedEvent] = [];
			listeners[listenedEvent].push(callback);
			if(listenedEvent==V.Constant.Event.onMessage){
				V.Messenger.init();
			}
		}
	}

	var unRegisterCallback = function(listenedEvent,callback){
		if((listenedEvent in listeners)){
			if(listeners[listenedEvent].indexOf(callback)!==-1){
				listeners[listenedEvent].splice(listeners[listenedEvent].indexOf(callback),1);
			}
		}
	}

	var notifyEvent = function(triggeredEvent,params,triggeredByUser){
		if(!listeners){
			return;
		}
		params = params || {};
		params.triggeredByUser = !(triggeredByUser===false);
		var eventListeners = listeners[triggeredEvent];
		if(eventListeners){
			for(var i=0; i<eventListeners.length; i++){
				eventListeners[i](params);
			}
		}
	}

	return {
			init 				: init,
			notifyEvent			: notifyEvent,
			registerCallback 	: registerCallback,
			unRegisterCallback 	: unRegisterCallback
	};

}) (VISH,jQuery);<commit_msg>Minor change<commit_after>VISH.EventsNotifier = (function(V,$,undefined){

	var listeners;
	// listeners['event'] = [callback1,callback2,...,callbackn];

	var init = function() {
		listeners = new Array();		
	};

	var registerCallback = function(listenedEvent,callback){
		if(listenedEvent in listeners){
			listeners[listenedEvent].push(callback);
		} else {
			listeners[listenedEvent] = [];
			listeners[listenedEvent].push(callback);
			if(listenedEvent==V.Constant.Event.onMessage){
				V.Messenger.init();
			}
		}
	};

	var unRegisterCallback = function(listenedEvent,callback){
		if((listenedEvent in listeners)){
			if(listeners[listenedEvent].indexOf(callback)!==-1){
				listeners[listenedEvent].splice(listeners[listenedEvent].indexOf(callback),1);
			}
		}
	};

	var notifyEvent = function(triggeredEvent,params,triggeredByUser){
		if(!listeners){
			return;
		}
		params = params || {};
		params.triggeredByUser = !(triggeredByUser===false);
		var eventListeners = listeners[triggeredEvent];
		if(eventListeners){
			for(var i=0; i<eventListeners.length; i++){
				eventListeners[i](params);
			}
		}
	};

	return {
			init 				: init,
			notifyEvent			: notifyEvent,
			registerCallback 	: registerCallback,
			unRegisterCallback 	: unRegisterCallback
	};

}) (VISH,jQuery);
{'fraction_non_alphanumeric': 0.1471273291925466, 'fraction_numerical': 0.0038819875776397515, 'mean_word_length': 4.752232142857143, 'pattern_counts': {'":': 0, '<': 5, '<?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': '6334764', 'n_tokens_mistral': 955, 'n_tokens_neox': 838, 'n_words': 120}