<commit_before>'use strict'

function JellyEmitter() {}
JellyEmitter.prototype = {
	emit: function (eventName) {
		var list = this._events && this._events[eventName]
		if (list) {
			var argLen = arguments.length
			if (argLen < 5) {
				argLen <= 1 ? a0(this, list) :
				argLen == 2 ? a1(this, list, arguments[1]) :
				argLen == 3 ? a2(this, list, arguments[1], arguments[2]) :
				              a3(this, list, arguments[1], arguments[2], arguments[3])
			} else {
				var args = new Array(argLen - 1)
				for (var i=1; i<argLen; i++) {args[i - 1] = arguments[i]}
				aX(this, list, args)
			}
			return true
		}
		return false
	},
	on: function (eventName, listener) {
		if (typeof listener !== 'function') {
			throw new TypeError('Event listener must be a function, not ' + (listener === null ? null : typeof listener) + '.')
		}
		var events = this._events || (this._events = Object.create(null))
		var list = events[eventName]
		if (!list) {
			events[eventName] = listener
		} else if (typeof list === 'function') {
			events[eventName] = [list, listener]
		} else {
			list.push(listener)
		}
		return this
	},
	once: function (eventName, listener) {
		if (typeof listener !== 'function') {
			throw new TypeError('Event listener must be a function, not ' + (listener === null ? null : typeof listener) + '.')
		}
		var fired = false
		function w() {
			listener.apply(this, arguments)
			if (!fired) {
				this.removeListener(eventName, w.originalListener)
				fired = true
			}
		}
		w.originalListener = listener.originalListener || listener
		return this.on(eventName, w)
	},
	removeListener: function (eventName, listener) {
		if (typeof listener !== 'function') {
			throw new TypeError('Event listener must be a function, not ' + (listener === null ? null : typeof listener) + '.')
		}
		var events = this._events
		if (events) {
			var list = events[eventName]
			if (typeof list === 'function') {
				if (list.originalListener ? list.originalListener === listener : list === listener) {
					delete events[eventName]
				}<commit_msg>added comment<commit_after>'use strict'

function JellyEmitter() {}
JellyEmitter.prototype = {
	emit: function (eventName) {
		var list = this._events && this._events[eventName]
		if (list) {
			var argLen = arguments.length
			if (argLen < 5) {
				argLen <= 1 ? a0(this, list) :
				argLen == 2 ? a1(this, list, arguments[1]) :
				argLen == 3 ? a2(this, list, arguments[1], arguments[2]) :
				              a3(this, list, arguments[1], arguments[2], arguments[3])
			} else {
				var args = new Array(argLen - 1)
				for (var i=1; i<argLen; i++) {args[i - 1] = arguments[i]}
				aX(this, list, args)
			}
			return true
		}
		return false
	},
	on: function (eventName, listener) {
		if (typeof listener !== 'function') {
			throw new TypeError('Event listener must be a function, not ' + (listener === null ? null : typeof listener) + '.')
		}
		var events = this._events || (this._events = Object.create(null))
		var list = events[eventName]
		if (!list) {
			events[eventName] = listener
		} else if (typeof list === 'function') {
			events[eventName] = [list, listener]
		} else {
			list.push(listener)
		}
		return this
	},
	once: function (eventName, listener) {
		if (typeof listener !== 'function') {
			throw new TypeError('Event listener must be a function, not ' + (listener === null ? null : typeof listener) + '.')
		}
		// This current implementation could cause event order to be changed in edge cases:
		// emitter.on('foo', bar)
		// emitter.on('foo', quux)
		// emitter.once('foo', bar)
		// emitter.emit('foo') // Event order: bar, quux, bar
		// emitter.emit('foo') // Event order: quux, bar
		var fired = false
		function w() {
			listener.apply(this, arguments)
			if (!fired) {
				this.removeListener(eventName, w.originalListener)
				fired = true
			}
		}
		w.originalListener = listener.originalListener || listener
		return this.on(eventName, w)
	},
	removeListener: function (eventName, listener) {
		if (typeof listener !== 'function') {
			throw new TypeError('Event listener must be a function, not ' + (listener === null ? null : typeof listener) + '.')
		}
		var events = this._events
		if (events) {
			var list = events[eventName]
			if (typeof list === 'function') {
				if (list.originalListener ? list.originalListener === listener : list === listener) {
					delete events[eventName]
				}
{'fraction_non_alphanumeric': 0.15002279981760147, 'fraction_numerical': 0.007751937984496124, 'mean_word_length': 3.305201177625123, 'pattern_counts': {'":': 0, '<': 9, '<?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': '2796904', 'n_tokens_mistral': 1596, 'n_tokens_neox': 1389, 'n_words': 411}