<commit_before>$.ajaxPrefilter(function( options ) {
    options.async = false;
});



var intervalID;
var groups;


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

    if (intervalID)
        clearInterval(intervalID)

    links = $(this).find('#id_links').val();
    links_arr = links.trim().split(/\s+/);

    $subscribers_table = $('#subscribers_table tbody');
    $subscribers_table.html('');

    groups = [];
    var i = 0;
    iterate(i);
});





function iterate(i) {
    generate_intersections_table();

    i++;
    if (i > links_arr.length)
        return

    link = links_arr[i];

    $.post(FETCH_GROUP_URL, {'link': link}, function(response) {
        social = response['social'];
        group = response['group'];

        cells_arr = [
            '<a href="%s">%s</a>'.replace(/%s/g, link),
            group['name'],
            group['members_in_db_count'],
            group['members_count'],
        ]<commit_msg>js: link fix, 'group not found' treated correctly<commit_after>$.ajaxPrefilter(function( options ) {
    options.async = false;
});



var intervalID;
var groups;


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

    if (intervalID)
        clearInterval(intervalID)

    links = $(this).find('#id_links').val();
    links_arr = links.trim().split(/\s+/);

    $subscribers_table = $('#subscribers_table tbody');
    $subscribers_table.html('');

    groups = [];
    var i = 0;
    iterate(i);
});





function iterate(i) {
    generate_intersections_table();

    link = links_arr[i];

    i++;
    if (i > links_arr.length)
        return

    $.post(FETCH_GROUP_URL, {'link': link}, function(response) {
        if (response['errors']) {
            $row = $('<tr>');
            $cell1 = $('<td>').html(link).appendTo($row);
            $cell2 = $('<td class="error" colspan=3>').html(response['errors']).appendTo($row);
            $subscribers_table.append($row);
            iterate(i); // iterate next link
            return
        }

        social = response['social'];
        group = response['group'];

        cells_arr = [
            '<a href="%s">%s</a>'.replace(/%s/g, link),
            group['name'],
            group['members_in_db_count'],
            group['members_count'],
        ]
{'fraction_non_alphanumeric': 0.18217734855136083, 'fraction_numerical': 0.0021949078138718174, 'mean_word_length': 2.506153846153846, 'pattern_counts': {'":': 0, '<': 10, '<?xml version=': 0, '>': 12, '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': '3395818', 'n_tokens_mistral': 750, 'n_tokens_neox': 710, 'n_words': 125}