<commit_before>/*! Kernel CI Dashboard | Licensed under the GNU GPL v3 (or later) */
define([
    'jquery',
    'bootstrap'
], function($) {
    'use strict';
    var err;

    err = {};

    // Create random ID value for the error notification.
    function randId(code) {
        return 'error-' + (Math.random() * ((code + 100) - code) + code);
    }

    function createErrorDiv(code, message) {
        var buttonNode,
            divNode;

        divNode = document.createElement('div');
        divNode.id = randId(code);
        divNode.className = 'alert alert-danger alert-dismissable';

        buttonNode = document.createElement('button');
        buttonNode.className = 'close';
        buttonNode.setAttribute('type', 'button');
        buttonNode.setAttribute('data-dismiss', 'alert');
        buttonNode.setAttribute('aria-hidden', 'true');
        buttonNode.insertAdjacentHTML('beforeend', '&times;');

        divNode.appendChild(buttonNode);

        if (message !== '' && message !== undefined && message !== null) {
            divNode.insertAdjacentHTML('beforeend', message);
        } else {
            divNode.appendChild(
                document.createTextNode(
                    'Error while loading data from the server ' +
                    '(error code: ' + code + ').')
            );
            divNode.appendChild(document.createTextNode(' '));
            divNode.appendChild(
                document.createTextNode(
                    'Please contanct the website administrator'));
        }

        return divNode;
    }

    function createError(code) {
        var divNode,
            errorElement;
<commit_msg>Spelling error in the error text :)<commit_after>/*! Kernel CI Dashboard | Licensed under the GNU GPL v3 (or later) */
define([
    'jquery',
    'bootstrap'
], function($) {
    'use strict';
    var err;

    err = {};

    // Create random ID value for the error notification.
    function randId(code) {
        return 'error-' + (Math.random() * ((code + 100) - code) + code);
    }

    function createErrorDiv(code, message) {
        var buttonNode,
            divNode;

        divNode = document.createElement('div');
        divNode.id = randId(code);
        divNode.className = 'alert alert-danger alert-dismissable';

        buttonNode = document.createElement('button');
        buttonNode.className = 'close';
        buttonNode.setAttribute('type', 'button');
        buttonNode.setAttribute('data-dismiss', 'alert');
        buttonNode.setAttribute('aria-hidden', 'true');
        buttonNode.insertAdjacentHTML('beforeend', '&times;');

        divNode.appendChild(buttonNode);

        if (message !== '' && message !== undefined && message !== null) {
            divNode.insertAdjacentHTML('beforeend', message);
        } else {
            divNode.appendChild(
                document.createTextNode(
                    'Error while loading data from the server ' +
                    '(error code: ' + code + ').')
            );
            divNode.appendChild(document.createTextNode(' '));
            divNode.appendChild(
                document.createTextNode(
                    'Please contact the website administrator'));
        }

        return divNode;
    }

    function createError(code) {
        var divNode,
            errorElement;

{'fraction_non_alphanumeric': 0.1266806095010457, 'fraction_numerical': 0.0023902001792650133, 'mean_word_length': 2.102873030583874, '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': '2222949', 'n_tokens_mistral': 892, 'n_tokens_neox': 847, 'n_words': 208}