<commit_before>package tehnut.lib.util.helper;

import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

public class LogHelper {

    private final Logger logger;
    private final boolean enabled;

    public LogHelper(Logger logger, boolean enabled) {
        this.logger = logger;
        this.enabled = enabled;
    }

    public LogHelper(Logger logger) {
        this(logger, true);
    }

    public LogHelper(String logger, boolean enabled) {
        this(LogManager.getLogger(logger), enabled);
    }

    public LogHelper(String logger) {
        this(logger, true);
    }

    public void info(String info, Object... format) {
        if (enabled)
            logger.info(info, format);
    }

    public void error(String error, Object... format) {
        if (enabled)
            logger.info(error, format);
    }

    public void debug(String debug, Object... format) {
        if (enabled)
            logger.info(debug, format);
    }

    public void severe(String severe, Object... format) {
        logger.fatal(severe, format);
    }

    public Logger getLogger() {
        return logger;<commit_msg>Fix LogHelper always sending to INFO<commit_after>package tehnut.lib.util.helper;

import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;

public class LogHelper {

    private final Logger logger;
    private final boolean enabled;

    public LogHelper(Logger logger, boolean enabled) {
        this.logger = logger;
        this.enabled = enabled;
    }

    public LogHelper(Logger logger) {
        this(logger, true);
    }

    public LogHelper(String logger, boolean enabled) {
        this(LogManager.getLogger(logger), enabled);
    }

    public LogHelper(String logger) {
        this(logger, true);
    }

    public void info(String info, Object... format) {
        if (enabled)
            logger.info(info, format);
    }

    public void error(String error, Object... format) {
        if (enabled)
            logger.error(error, format);
    }

    public void debug(String debug, Object... format) {
        if (enabled)
            logger.debug(debug, format);
    }

    public void severe(String severe, Object... format) {
        logger.fatal(severe, format);
    }

    public Logger getLogger() {
        return logger;
{'fraction_non_alphanumeric': 0.10399656209712076, 'fraction_numerical': 0.0017189514396218307, 'mean_word_length': 2.4035087719298245, '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': '2363051', 'n_tokens_mistral': 657, 'n_tokens_neox': 631, 'n_words': 176}