<commit_before>$(document).ready(function () {
    // Initialize date picker
    $('#date').bootstrapMaterialDatePicker({weekStart: 0, time: false});

    // Disable submit on enter
    $('#hmAttendanceForm').on('keyup keypress', function (e) {
        var keyCode = e.keyCode || e.which;
        if (keyCode === 13) {
            e.preventDefault();
            return false;
        }
    });

    // Update attendance picker colors when changed
    $('.attendance-Attended').click(function () {
        $(this).addClass('btn-success').siblings().removeClass('btn-danger').removeClass('btn-info');
    });

    $('.attendance-Absent').click(function () {
        $(this).addClass('btn-danger').siblings().removeClass('btn-success').removeClass('btn-info');
    });

    $('.attendance-Excused').click(function () {
        $(this).addClass('btn-info').siblings().removeClass('btn-success').removeClass('btn-danger');
    });

    // Show comment box when add comment is clicked
    $('.comment-trigger').click(function () {
        $(this).hide();
        $(this).siblings(".comment-field").show();
    });

    $("#submit").click(function (e) {
        e.preventDefault();

        rows = $("#attendees").children()

        var freshmen = [];
        var upperclassmen = [];

        rows.each(function (row) {
            row = rows[row];
            member = row.attributes.member.value;
            status = $("input:radio[name=attendance-" + member + "]:checked").val()
            excuse = $("#comment-" + member).val()

            if (!isNaN(member)) {
                freshmen.push({
                    'id': member,
                    'excuse': excuse,
                    'status': status
                })
            } else {
                upperclassmen.push({
                    'uid': member,
                    'excuse': excuse,
                    'status': status
                })
            }
        });

        $.ajax({
            url: '/attendance/submit/hm',
            type: 'POST',
            contentType: "application/json; charset=utf-8",
            dataType: 'json',
            data: JSON.stringify({
                "freshmen": freshmen,
                "members": upperclassmen,
                "timestamp": $("#date").val()
            }),
            error: function () {
                alertify.error("Error submitting attendance.");
            },
            success: function (res) {
                alertify.success("Attendance submitted successfully.");
            }
        });

    });
});
<commit_msg>Semicolons<commit_after>$(document).ready(function () {
    // Initialize date picker
    $('#date').bootstrapMaterialDatePicker({weekStart: 0, time: false});

    // Disable submit on enter
    $('#hmAttendanceForm').on('keyup keypress', function (e) {
        var keyCode = e.keyCode || e.which;
        if (keyCode === 13) {
            e.preventDefault();
            return false;
        }
    });

    // Update attendance picker colors when changed
    $('.attendance-Attended').click(function () {
        $(this).addClass('btn-success').siblings().removeClass('btn-danger').removeClass('btn-info');
    });

    $('.attendance-Absent').click(function () {
        $(this).addClass('btn-danger').siblings().removeClass('btn-success').removeClass('btn-info');
    });

    $('.attendance-Excused').click(function () {
        $(this).addClass('btn-info').siblings().removeClass('btn-success').removeClass('btn-danger');
    });

    // Show comment box when add comment is clicked
    $('.comment-trigger').click(function () {
        $(this).hide();
        $(this).siblings(".comment-field").show();
    });

    $("#submit").click(function (e) {
        e.preventDefault();

        rows = $("#attendees").children();

        var freshmen = [];
        var upperclassmen = [];

        rows.each(function (row) {
            row = rows[row];
            member = row.attributes.member.value;
            status = $("input:radio[name=attendance-" + member + "]:checked").val();
            excuse = $("#comment-" + member).val();

            if (!isNaN(member)) {
                freshmen.push({
                    'id': member,
                    'excuse': excuse,
                    'status': status
                })
            } else {
                upperclassmen.push({
                    'uid': member,
                    'excuse': excuse,
                    'status': status
                })
            }
        });

        $.ajax({
            url: '/attendance/submit/hm',
            type: 'POST',
            contentType: "application/json; charset=utf-8",
            dataType: 'json',
            data: JSON.stringify({
                "freshmen": freshmen,
                "members": upperclassmen,
                "timestamp": $("#date").val()
            }),
            error: function () {
                alertify.error("Error submitting attendance.");
            },
            success: function () {
                alertify.success("Attendance submitted successfully.");
            }
        });

    });
});

{'fraction_non_alphanumeric': 0.1704079640835448, 'fraction_numerical': 0.0015615850087839158, 'mean_word_length': 1.69826224328594, 'pattern_counts': {'":': 6, '<': 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': '234904', 'n_tokens_mistral': 1363, 'n_tokens_neox': 1329, 'n_words': 233}