<commit_before>;(function (window) {
    /*if ('DOMTokenList' in window) {
        return;
    }*/

    var inArray = function (array, value) {
        var i;

        for (i = 0; i < array.length; i++) {
            if (array[i] === value) {
                return i;
            }
        }

        return -1;
    };

    var DOMTokenList2 = function () {
        this.tokens = [];
        this.length = 0;
    };

    DOMTokenList2.prototype.add = function () {
        var i,
            tokens = [].slice.call(arguments);

        for (i = 0; i < tokens.length; i++) {
            if (!this.contains(tokens[i])) {
                this.tokens.push(tokens[i]);
            }
        }
    };

    DOMTokenList2.prototype.contains = function (token) {
        if (token === '' || /\s/.test(token)) {
            throw new Error('Token must not be empty or contain whitespace.');
        }

        return inArray(this.tokens, token) !== -1;
    };

    DOMTokenList2.prototype.item = function (index) {
        return this.tokens[index] || null;
    };

    DOMTokenList2.prototype.remove = function () {
        var i,
            key,
            tokens = [].slice.call(arguments);

        for (i = 0; i < tokens.length; i++) {
            key = inArray(this.tokens, tokens[i]);

            if (key !== -1) {
                this.tokens.splice(key, 1);
            }
        }
    };

    DOMTokenList2.prototype.toggle = function (token, force) {
        if (token === '' || /\s/.test(token)) {
            throw new Error('Token must not be empty or contain whitespace.');
        }

        if (this.contains(token)) {
            if (!force) {
                this.remove(token);

                return false;
            }

            return true;
        }

        if (force === false) {
            return false;
        }

        this.add(token);

        return true;
    };

    DOMTokenList2.prototype.toString = function () {
        return this.tokens.join(' ');
    };<commit_msg>Code formatting<commit_after>;(function (window) {
    /*if ('DOMTokenList' in window) {
        return;
    }*/

    var inArray = function (array, value) {
        var i;

        for (i = 0; i < array.length; i++) {
            if (array[i] === value) {
                return i;
            }
        }

        return -1;
    };

    var DOMTokenList2 = function () {
        this.tokens = [];
        this.length = 0;
    };

    DOMTokenList2.prototype.add = function () {
        var i;
        var tokens = [].slice.call(arguments);

        for (i = 0; i < tokens.length; i++) {
            if (!this.contains(tokens[i])) {
                this.tokens.push(tokens[i]);
            }
        }
    };

    DOMTokenList2.prototype.contains = function (token) {
        if (token === '' || /\s/.test(token)) {
            throw new Error('Token must not be empty or contain whitespace.');
        }

        return inArray(this.tokens, token) !== -1;
    };

    DOMTokenList2.prototype.item = function (index) {
        return this.tokens[index] || null;
    };

    DOMTokenList2.prototype.remove = function () {
        var i;
        var key;
        var tokens = [].slice.call(arguments);

        for (i = 0; i < tokens.length; i++) {
            key = inArray(this.tokens, tokens[i]);

            if (key !== -1) {
                this.tokens.splice(key, 1);
            }
        }
    };

    DOMTokenList2.prototype.toggle = function (token, force) {
        if (token === '' || /\s/.test(token)) {
            throw new Error('Token must not be empty or contain whitespace.');
        }

        if (this.contains(token)) {
            if (!force) {
                this.remove(token);
                return false;
            }

            return true;
        }

        if (force === false) {
            return false;
        }

        this.add(token);
        return true;
    };

    DOMTokenList2.prototype.toString = function () {
        return this.tokens.join(' ');
    };
{'fraction_non_alphanumeric': 0.1456359102244389, 'fraction_numerical': 0.007481296758104738, 'mean_word_length': 1.4294367050272563, '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': '5166941', 'n_tokens_mistral': 1206, 'n_tokens_neox': 1146, 'n_words': 270}