BallStateCBER/datacenter-plugin-cakephp3

View on GitHub

Showing 955 of 1,787 total issues

Function init has a Cognitive Complexity of 25 (exceeds 5 allowed). Consider refactoring.
Open

    init : function(ed) {
        var f = document.forms[0], nl = f.elements, ed = tinyMCEPopup.editor, dom = ed.dom, n = ed.selection.getNode();

        tinyMCEPopup.resizeToInnerSize();
        this.fillClassList('class_list');
Severity: Minor
Found in webroot/js/tiny_mce/plugins/advimage/js/image.js - About 3 hrs to fix

Cognitive Complexity

Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

A method's cognitive complexity is based on a few simple rules:

  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
  • Code is considered more complex for each "break in the linear flow of the code"
  • Code is considered more complex when "flow breaking structures are nested"

Further reading

Function toggle has 89 lines of code (exceeds 25 allowed). Consider refactoring.
Open

PROTOTYPE.toggle = function(state, event) {
    var cache = this.cache,
        options = this.options,
        tooltip = this.tooltip;

Severity: Major
Found in webroot/js/jquery.qtip.js - About 3 hrs to fix

    File table.js has 314 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    tinyMCEPopup.requireLangPack();
    
    var action, orgTableWidth, orgTableHeight, dom = tinyMCEPopup.editor.dom;
    
    function insertTable() {
    Severity: Minor
    Found in webroot/js/tiny_mce/plugins/table/js/table.js - About 3 hrs to fix

      Function errorHTML has 87 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

      function errorHTML(e, rootHref) {
          var id = 'less-error-message:' + extractId(rootHref || "");
          var template = '<li><label>{line}</label><pre class="{class}">{content}</pre></li>';
          var elem = document.createElement('div'), timer, content, errors = [];
          var filename = e.filename || rootHref;
      Severity: Major
      Found in webroot/js/less-1.7.3.js - About 3 hrs to fix

        Function _assignEvents has 87 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

        PROTOTYPE._assignEvents = function() {
            var options = this.options,
                posOptions = options.position,
        
                tooltip = this.tooltip,
        Severity: Major
        Found in webroot/js/jquery.qtip.js - About 3 hrs to fix

          Function toCSS has 87 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

                      root.toCSS = (function (evaluate) {
                          return function (options, variables) {
                              options = options || {};
                              var evaldRoot,
                                  css,
          Severity: Major
          Found in webroot/js/less-1.7.3.js - About 3 hrs to fix

            Function load has 87 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                load: function(url, settings) {
                    settings = (typeof settings == 'boolean' ? {addTo: settings} :
                        (typeof settings == 'function' ? {onLoad: settings} :
                        (typeof settings == 'string' ? {parent: settings} : 
                        (typeof settings == 'object' && settings.nodeName ? {parent: settings} :
            Severity: Major
            Found in webroot/js/jquery.svg.js - About 3 hrs to fix

              Function send has 86 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                              send: function( headers, complete ) {
              
                                  // Get a new xhr
                                  var xhr = s.xhr(),
                                      handle,
              Severity: Major
              Found in webroot/js/jquery-1.7.1.js - About 3 hrs to fix

                Function trigger has 86 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                    trigger: function( event, data, elem, onlyHandlers ) {
                        var handle, ontype, cur,
                            bubbleType, special, tmp, i,
                            eventPath = [ elem || document ],
                            type = core_hasOwn.call( event, "type" ) ? event.type : event,
                Severity: Major
                Found in webroot/jquery-ui-1.11.3.custom/external/jquery/jquery.js - About 3 hrs to fix

                  Function joinSelector has 85 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                      joinSelector: function (paths, context, selector) {
                  
                          var i, j, k, 
                              hasParentSelector, newSelectors, el, sel, parentSel, 
                              newSelectorPath, afterParentJoin, newJoinedSelector, 
                  Severity: Major
                  Found in webroot/js/less-1.7.3.js - About 3 hrs to fix

                    Function setupFormData has 85 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                    function setupFormData() {
                        var ce = document.getElementById('container'), f = document.forms[0], s, b, i;
                    
                        // Setup text fields
                    
                    
                    Severity: Major
                    Found in webroot/js/tiny_mce/plugins/style/js/props.js - About 3 hrs to fix

                      Function forceRoots has 85 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                              forceRoots : function(ed, e) {
                                  var t = this, ed = t.editor, b = ed.getBody(), d = ed.getDoc(), se = ed.selection, s = se.getSel(), r = se.getRng(), si = -2, ei, so, eo, tr, c = -0xFFFFFF;
                                  var nx, bl, bp, sp, le, nl = b.childNodes, i, n, eid;
                      
                                  // Fix for bug #1863847
                      Severity: Major
                      Found in webroot/js/tiny_mce/tiny_mce_src.js - About 3 hrs to fix

                        Function getBookmark has 85 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                                getBookmark : function(si) {
                                    var t = this, r = t.getRng(), tr, sx, sy, vp = t.dom.getViewPort(t.win), e, sp, bp, le, c = -0xFFFFFF, s, ro = t.dom.getRoot(), wb = 0, wa = 0, nv;
                                    sx = vp.x;
                                    sy = vp.y;
                        
                        
                        Severity: Major
                        Found in webroot/js/tiny_mce/tiny_mce_src.js - About 3 hrs to fix

                          File Installer.php has 307 lines of code (exceeds 250 allowed). Consider refactoring.
                          Open

                          <?php
                          declare(strict_types=1);
                          
                          /**
                           * CakePHP(tm) : Rapid Development Framework (https://cakephp.org)
                          Severity: Minor
                          Found in src/Console/Installer.php - About 3 hrs to fix

                            Function Animation has 84 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                            function Animation( elem, properties, options ) {
                                var result,
                                    stopped,
                                    index = 0,
                                    length = animationPrefilters.length,
                            Severity: Major
                            Found in webroot/jquery-ui-1.11.3.custom/external/jquery/jquery.js - About 3 hrs to fix

                              Function _doKeyDown has 84 lines of code (exceeds 25 allowed). Consider refactoring.
                              Open

                                  _doKeyDown: function(event) {
                                      var onSelect, dateStr, sel,
                                          inst = $.datepicker._getInst(event.target),
                                          handled = true,
                                          isRTL = inst.dpDiv.is(".ui-datepicker-rtl");
                              Severity: Major
                              Found in webroot/jquery-ui-1.11.3.custom/jquery-ui.js - About 3 hrs to fix

                                Consider simplifying this complex logical expression.
                                Open

                                                    if((corner.x === LEFT && realX >= compareX) ||
                                                    (corner.x === RIGHT && realX <= compareX) ||
                                                    (corner.x === CENTER && (realX < compareX || realX > (result.width - compareX))) ||
                                                    (corner.y === TOP && realY >= compareY) ||
                                                    (corner.y === BOTTOM && realY <= compareY) ||
                                Severity: Critical
                                Found in webroot/js/jquery.qtip.js - About 3 hrs to fix

                                  Function clean has 83 lines of code (exceeds 25 allowed). Consider refactoring.
                                  Open

                                      clean: function( elems, context, fragment, scripts ) {
                                          var checkScriptType;
                                  
                                          context = context || document;
                                  
                                  
                                  Severity: Major
                                  Found in webroot/js/jquery-1.7.1.js - About 3 hrs to fix

                                    Function animate has 83 lines of code (exceeds 25 allowed). Consider refactoring.
                                    Open

                                        animate: function( prop, speed, easing, callback ) {
                                            var optall = jQuery.speed( speed, easing, callback );
                                    
                                            if ( jQuery.isEmptyObject( prop ) ) {
                                                return this.each( optall.complete, [ false ] );
                                    Severity: Major
                                    Found in webroot/js/jquery-1.7.1.js - About 3 hrs to fix

                                      Function moveToBookmark has 83 lines of code (exceeds 25 allowed). Consider refactoring.
                                      Open

                                              moveToBookmark : function(b) {
                                                  var t = this, r = t.getRng(), s = t.getSel(), ro = t.dom.getRoot(), sd, nvl, nv;
                                      
                                                  function getPos(r, sp, ep) {
                                                      var w = t.dom.doc.createTreeWalker(r, NodeFilter.SHOW_TEXT, null, false), n, p = 0, d = {}, o, v, wa, wb;
                                      Severity: Major
                                      Found in webroot/js/tiny_mce/tiny_mce_src.js - About 3 hrs to fix
                                        Severity
                                        Category
                                        Status
                                        Source
                                        Language