<commit_before>'use strict';

var value = require('es5-ext/object/valid-value')

  , hasOwnProperty = Object.prototype.hasOwnProperty;

module.exports = function (emitter) {
	var type, data;

	value(emitter);

	if (arguments[1] != null) {
		type = arguments[1];
		data = emitter.hasOwnProperty('__ee__') && emitter.__ee__;
		if (!data) return;
		if (hasOwnProperty.call(data, type)) delete data[type];
		return;
	}
	if (emitter.hasOwnProperty('__ee__')) delete emitter.__ee__;
};<commit_msg>Cleanup logic<commit_after>'use strict';

var value = require('es5-ext/object/valid-value')

  , hasOwnProperty = Object.prototype.hasOwnProperty;

module.exports = function (emitter/*, type*/) {
	var type = arguments[1], data;

	value(emitter);

	if (type !== undefined) {
		data = emitter.hasOwnProperty('__ee__') && emitter.__ee__;
		if (!data) return;
		if (hasOwnProperty.call(data, type)) delete data[type];
		return;
	}
	if (emitter.hasOwnProperty('__ee__')) delete emitter.__ee__;
};
{'fraction_non_alphanumeric': 0.159877800407332, 'fraction_numerical': 0.0050916496945010185, 'mean_word_length': 5.067901234567901, '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': '1594456', 'n_tokens_mistral': 345, 'n_tokens_neox': 327, 'n_words': 71}