<commit_before>(function() {
	var logLevels = {
		FULL: "FULL", // record all logs
		ERROR: "ERROR", // only record errors and warnings
		NONE: "NONE", // record nothing from this module
	}

	logTypes = {
		DEBUG: 3,
		WARNING: 2,
		ERROR: 1,
	}

	var recordFunctions = {};

	recordFunctions[logLevels.FULL] = function(name, log, type) {
		console.log(name + ": " + log);
	}

	recordFunctions[logLevels.ERROR] = function(name, log, type) {
		if (log < logtTypes.WARNING) {
			console.log(name + ": " + log);
		}
	}

	recordFunctions[logLevels.NONE] = function() {}

	var currentLogs = {
		"app": logLevels.FULL,
		"TodosController": logLevels.FULL,
	}

	window.loggerInstance = function(name) {
		var recordFunction = recordFunctions[currentLogs[name]] || function(){};

		return {
			record: function(message){
				recordFunction(name, message);
			},
		};
	}
})()
<commit_msg>Starting to work on different log levels.<commit_after>(function() {
	var logLevels = {
		FULL: "FULL", // record all logs
		ERROR: "ERROR", // only record errors and warnings
		NONE: "NONE", // record nothing from this module
	}

	logTypes = {
		DEBUG: 3,
		WARNING: 2,
		ERROR: 1,
	}

	var recordFunctions = {};

	recordFunctions[logLevels.FULL] = function(name, log, type) {
		console.log(name + ": " + log);
	}

	recordFunctions[logLevels.ERROR] = function(name, log, type) {
		if (log < logtTypes.WARNING) {
			console.log(name + ": " + log);
		}
	}

	recordFunctions[logLevels.NONE] = function() {}

	var currentLogs = {
		"app": logLevels.FULL,
		"TodosController": logLevels.FULL,
	}

	window.loggerInstance = function(name) {
		var recordFunction = recordFunctions[currentLogs[name]] || function(){};

		return {
			d: function(message) {

			},
			w: function(message) {

			},
			record: function(message){
				recordFunction(name, message);
			},
		};
	}
})()

{'fraction_non_alphanumeric': 0.15945945945945947, 'fraction_numerical': 0.003243243243243243, 'mean_word_length': 3.6044776119402986, 'pattern_counts': {'":': 8, '<': 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': '83806', 'n_tokens_mistral': 720, 'n_tokens_neox': 628, 'n_words': 140}