<commit_before>Ext.namespace('ui','ui.task');

ui.task.LoadConfigTask = function(config)
{
    Ext.apply(this, config);

    XHR({
        params  : { task : 'getConf' },
        success : function(r)
        {
            var o = Ext.decode(r.responseText);

            PhDOE.user.login = o.mess.userLogin;
            PhDOE.user.lang  = o.mess.userLang;
            PhDOE.user.isAnonymous = o.mess.userIsAnonymous;
            PhDOE.user.isGlobalAdmin = o.mess.userIsGlobalAdmin;
            PhDOE.user.isLangAdmin = o.mess.userIsLangAdmin;
            PhDOE.user.conf = o.mess.userConf;

            PhDOE.project   = o.mess.project;
            PhDOE.app.conf   = o.mess.appConf;

            if( o.mess.topicInfo ) {
                PhDOE.topic.author = o.mess.topicInfo.author;
                PhDOE.topic.content = o.mess.topicInfo.content;
                PhDOE.topic.topicDate = Date.parseDate(o.mess.topicInfo.topicDate, 'Y-m-d H:i:s');
                PhDOE.topic.topicDate = PhDOE.topic.topicDate.format(_('Y-m-d, H:i'));
            }
            
            //For the theme, we apply it.
            Ext.get('appTheme').dom.href = PhDOE.user.conf.main.theme;

            // Draw the interface
            PhDOE.drawInterface();
        }
    });
};<commit_msg>Load auth info<commit_after>Ext.namespace('ui','ui.task');

ui.task.LoadConfigTask = function(config)
{
    Ext.apply(this, config);

    XHR({
        params  : { task : 'getConf' },
        success : function(r)
        {
            var o = Ext.decode(r.responseText);

            PhDOE.user.login = o.mess.userLogin;
            PhDOE.user.lang  = o.mess.userLang;
            PhDOE.user.authService  = o.mess.authService;
            PhDOE.user.authServiceID  = o.mess.authServiceID;
            PhDOE.user.isAnonymous = o.mess.userIsAnonymous;
            PhDOE.user.isGlobalAdmin = o.mess.userIsGlobalAdmin;
            PhDOE.user.isLangAdmin = o.mess.userIsLangAdmin;
            PhDOE.user.conf = o.mess.userConf;
            PhDOE.user.anonymousIdent = o.mess.userAnonymousIdent;

            PhDOE.project   = o.mess.project;
            PhDOE.app.conf   = o.mess.appConf;

            if( o.mess.topicInfo ) {
                PhDOE.topic.author = o.mess.topicInfo.author;
                PhDOE.topic.content = o.mess.topicInfo.content;
                PhDOE.topic.topicDate = Date.parseDate(o.mess.topicInfo.topicDate, 'Y-m-d H:i:s');
                PhDOE.topic.topicDate = PhDOE.topic.topicDate.format(_('Y-m-d, H:i'));
            }
            
            //For the theme, we apply it.
            Ext.get('appTheme').dom.href = PhDOE.user.conf.main.theme;

            // Draw the interface
            PhDOE.drawInterface();
        }
    });
};

{'fraction_non_alphanumeric': 0.13270142180094788, 'fraction_numerical': 0.0, 'mean_word_length': 1.7141444114737883, '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': '4864738', 'n_tokens_mistral': 950, 'n_tokens_neox': 899, 'n_words': 118}