<commit_before>var pi_user_id = "";
var pi_user_code = "";
var accessToken = "";
var passkey = "";
const Pi = window.Pi;

function set_points(points) {
    if(pi_user_id != "" && pi_user_code != "")
    {
        var data = {
            'pi_user_id': pi_user_id,
            'pi_user_code': pi_user_code,
            'points': points,
            'app_client': 'auth_platform',
            'passkey': passkey,
            'accessToken': accessToken,
            'csrf_token': odoo.csrf_token,
        };
        $.ajaxSetup({async: false});
        return $.post( "/pi-points", data).done(function(data) {
            data = JSON.parse(data);
            if(data.result && points > 0)
                alert("You won " + points + " points");
        }).fail(function() {
            
        });
    }
}

$( document ).ready(function() {
    function get_user() {
        if(pi_user_id != "" && pi_user_code != "")
        {
            var data = {
                        'pi_user_id': pi_user_id,
                        'pi_user_code': pi_user_code,
                        'accessToken': accessToken,
                        'csrf_token': odoo.csrf_token,
                    };
            $.ajaxSetup({async: false});
            return $.post( "/get-user", data).done(function(data) {
                data = JSON.parse(data);
                if(data.result)
                {
                    passkey=data.passkey;
                    if(data.unblocked)
                    {
                        $("#pi_donate").hide();
                        $("#button_click").hide();
                        $('#chess-tab').show();
                        $('#chess-tab').click();
                        alert(all_was_loaded_lib);
                        alert(all_was_loaded);
                        if(all_was_loaded_lib == "mobile")
                        {
                            if(all_was_loaded)
                            {
                                setTimeout(function() {
                                    setMobileBoard();
                                }, 1000);
                            }else{
                                setTimeout(function() {
                                    setMobileBoard();
                                }, 10000);
                            }
                        }else if(all_was_loaded_lib == "desktop")
                        {
                            if(all_was_loaded)
                            {
                                setTimeout(function() {
                                    setDesktopBoard();
                                }, 1000);
                            }else{
                                setTimeout(function() {
                                    setDesktopBoard();
                                }, 10000);
                            }
                        }
                    }
                    else<commit_msg>Upgrade<commit_after>var pi_user_id = "";
var pi_user_code = "";
var accessToken = "";
var passkey = "";
const Pi = window.Pi;

function set_points(points) {
    if(pi_user_id != "" && pi_user_code != "")
    {
        var data = {
            'pi_user_id': pi_user_id,
            'pi_user_code': pi_user_code,
            'points': points,
            'app_client': 'auth_platform',
            'passkey': <PASSWORD>key,
            'accessToken': accessToken,
            'csrf_token': odoo.csrf_token,
        };
        $.ajaxSetup({async: false});
        return $.post( "/pi-points", data).done(function(data) {
            data = JSON.parse(data);
            if(data.result && points > 0)
                alert("You won " + points + " points");
        }).fail(function() {
            
        });
    }
}

$( document ).ready(function() {
    function get_user() {
        if(pi_user_id != "" && pi_user_code != "")
        {
            var data = {
                        'pi_user_id': pi_user_id,
                        'pi_user_code': pi_user_code,
                        'accessToken': accessToken,
                        'csrf_token': odoo.csrf_token,
                    };
            $.ajaxSetup({async: false});
            return $.post( "/get-user", data).done(function(data) {
                data = JSON.parse(data);
                if(data.result)
                {
                    passkey=data.passkey;
                    if(data.unblocked)
                    {
                        $("#pi_donate").hide();
                        $("#button_click").hide();
                        $('#chess-tab').show();
                        $('#chess-tab').click();
                        
                        if(all_was_loaded_lib == "mobile")
                        {
                            if(all_was_loaded)
                            {
                                setTimeout(function() {
                                    setMobileBoard();
                                }, 1000);
                            }else{
                                setTimeout(function() {
                                    setMobileBoard();
                                }, 10000);
                            }
                        }else if(all_was_loaded_lib == "desktop")
                        {
                            if(all_was_loaded)
                            {
                                setTimeout(function() {
                                    setDesktopBoard();
                                }, 1000);
                            }else{
                                setTimeout(function() {
                                    setDesktopBoard();
                                }, 10000);
                            }
                        }
                    }
                    else
{'fraction_non_alphanumeric': 0.11338962605548854, 'fraction_numerical': 0.006548337067034293, 'mean_word_length': 0.827455919395466, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 6, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 16, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1888677', 'n_tokens_mistral': 1450, 'n_tokens_neox': 1348, 'n_words': 201}