All files / web/bundles/pimui/js jquery-setup.js

55.56% Statements 5/9
0% Branches 0/4
33.33% Functions 1/3
55.56% Lines 5/9

Press n or j to go to the next uncovered block, b, p or k for the previous block.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 231183x     1183x         1183x       1183x               1183x    
define(['jquery'],
function ($) {
    'use strict';
    $.ajaxSetup({
        headers: {
            'X-CSRF-Header': 1
        }
    });
    $.expr[':'].parents = function (a, i, m) {
        return $(a).parents(m[3]).length < 1;
    };
    // used to indicate app's activity, such as AJAX request or redirection, etc.
    $.isActive = $.proxy(function (flag) {
        if ($.type(flag) !== 'undefined') {
            this.active = flag;
        }
 
        return $.active || this.active;
    }, {active: false});
 
    return $;
});