<commit_before>// Remember: This file is loaded before jQuery!

// Check if the current month on user device is December...
if (new Date().getMonth() === 11) {
    // Enable the christmas functions! Happy holidays from Wruczek! :D

    // Load and enable the christmas theme
    var stylesheet = document.createElement('link');
    stylesheet.href = 'css/christmas-theme.css';
    stylesheet.rel = 'stylesheet';
    document.head.appendChild(stylesheet);

    // Load and enable the snow
    var script = document.createElement('script');
    script.src = 'https://cdnjs.cloudflare.com/ajax/libs/JQuery-Snowfall/1.7.4/snowfall.jquery.min.js';
    document.head.appendChild(script);

    // Wait for the snowfall script and jQuery to load
    window.addEventListener('load', function () {
        defer(proceedWithJquery);
    });
}

function defer(method) {
    if (window.jQuery)
        method();
    else
        setTimeout(function() { defer(method) }, 50);
}

function proceedWithJquery() {
    $(document).snowfall({
        flakeCount: ($(document).width() > 992 ? 500 : 100),
        flakeIndex: -1,
        minSize: 4,
        maxSize: 5,
        minSpeed: 1,
        maxSpeed: 2,
        round: true,
        shadow: true
    });

    // Change background artist in the footer
    $('#background-artist').html('<a href="http://www.publicdomainpictures.net/view-image.php?image=28562&picture=christmas-bulbs-red-background">Debi Geroux - Public Domain</a>');
}<commit_msg>Fixed more problems with snowfall not being loaded<commit_after>// Remember: This file is loaded before jQuery!

// Check if the current month on user device is December...
if (new Date().getMonth() === 11) {
    // Enable the christmas functions! Happy holidays from Wruczek! :D

    // Load and enable the christmas theme
    var stylesheet = document.createElement('link');
    stylesheet.href = 'css/christmas-theme.css';
    stylesheet.rel = 'stylesheet';
    document.head.appendChild(stylesheet);

    // Load and enable the snow
    var script = document.createElement('script');
    script.src = 'https://cdnjs.cloudflare.com/ajax/libs/JQuery-Snowfall/1.7.4/snowfall.min.js';
    document.head.appendChild(script);

    window.addEventListener('load', function () {
        snowFall.snow(document.body, {
            flakeCount: (document.body.clientWidth > 992 ? 500 : 100),
            flakeIndex: -1,
            minSize: 4,
            maxSize: 5,
            minSpeed: 1,
            maxSpeed: 2,
            round: true,
            shadow: true
        });

        // Change background artist in the footer
        document.getElementById('background-artist').innerHTML = '<a href="http://www.publicdomainpictures.net/view-image.php?image=28562&picture=christmas-bulbs-red-background">Debi Geroux - Public Domain</a>';
    });
}
{'fraction_non_alphanumeric': 0.1326963906581741, 'fraction_numerical': 0.017692852087756547, 'mean_word_length': 2.8410326086956523, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 9, 'https://': 2, 'lorem ipsum': 0, 'www.': 2, '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': '6765109', 'n_tokens_mistral': 871, 'n_tokens_neox': 800, 'n_words': 207}