<commit_before>/**
 * Created by Shadowgun on 24.02.2015.
 */
Imcms.Language = {};
Imcms.Language.Loader = function () {
    this.init();
};
Imcms.Language.Loader.prototype = {
    _api: {},
    init: function () {
        this._api = new Imcms.Language.API();
    },
    read: function (callback) {
        this._api.read({}, callback);
    }
};

Imcms.Language.API = function () {

};
Imcms.Language.API.prototype = {
    read: function (request, response) {
        $.ajax({
            url: Imcms.Linker.get("language"),
            type: "GET",
            data: request,
            success: response
        });
    }
};<commit_msg>IMCMS-150 - Rewrite js hell in imCMS and use AMD mechanism: - Refactored Language API as module.<commit_after>/**
 * Created by Shadowgun on 24.02.2015.
 *
 * Refactored by <NAME>, 2017
 */
(function (Imcms) {
    var languageUrl = Imcms.Linker.get("language"),
        api = {};

    Imcms.Language = {};
    Imcms.Language.Loader = function () {
        this.init();
    };
    Imcms.Language.Loader.prototype = {
        init: function () {
            api = new Imcms.REST.API();
        },
        read: function (callback) {
            api.get({}, callback);
        }
    };

    return Imcms;
})(Imcms);
{'fraction_non_alphanumeric': 0.1606714628297362, 'fraction_numerical': 0.01838529176658673, 'mean_word_length': 2.083743842364532, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 4, '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': '2757113', 'n_tokens_mistral': 426, 'n_tokens_neox': 385, 'n_words': 86}