Showing 5,781 of 10,536 total issues

Avoid deeply nested control flow statements.
Open

              if (col + c < 0 || moduleCount <= col + c) {
                continue;
              }
Severity: Major
Found in myems-admin/js/angular/qrcode.js - About 45 mins to fix

    Avoid deeply nested control flow statements.
    Open

                        if (matchedKeys[key]) return;
    Severity: Major
    Found in myems-admin/js/angular/angular-messages.js - About 45 mins to fix

      Avoid deeply nested control flow statements.
      Open

                    if (dark == qrcode.isDark(row + r, col + c) ) {
                      sameCount += 1;
                    }
      Severity: Major
      Found in myems-admin/js/angular/qrcode.js - About 45 mins to fix

        Avoid deeply nested control flow statements.
        Open

                      if (r == -2 || r == 2 || c == -2 || c == 2
                          || (r == 0 && c == 0) ) {
                        _modules[row + r][col + c] = true;
                      } else {
                        _modules[row + r][col + c] = false;
        Severity: Major
        Found in myems-admin/js/angular/qrcode.js - About 45 mins to fix

          Avoid deeply nested control flow statements.
          Open

                        if (bitIndex == -1) {
                          byteIndex += 1;
                          bitIndex = 7;
                        }
          Severity: Major
          Found in myems-admin/js/angular/qrcode.js - About 45 mins to fix

            Avoid deeply nested control flow statements.
            Open

                          if (r == 0 && c == 0) {
                            continue;
                          }
            Severity: Major
            Found in myems-admin/js/angular/qrcode.js - About 45 mins to fix

              Function RegisteredHook has 6 arguments (exceeds 4 allowed). Consider refactoring.
              Open

                      function RegisteredHook(tranSvc, eventType, callback, matchCriteria, removeHookFromRegistry, options) {
              Severity: Minor
              Found in myems-admin/js/ui-router/angular-ui-router.js - About 45 mins to fix

                Avoid deeply nested control flow statements.
                Open

                              if (mask) {
                                dark = !dark;
                              }
                Severity: Major
                Found in myems-admin/js/angular/qrcode.js - About 45 mins to fix

                  Avoid deeply nested control flow statements.
                  Open

                              if (node === inertBodyElement) break;
                  Severity: Major
                  Found in myems-admin/js/angular/angular-sanitize.js - About 45 mins to fix

                    Avoid deeply nested control flow statements.
                    Open

                                if (node.nodeType === 1) {
                                  handler.end(node.nodeName.toLowerCase());
                                }
                    Severity: Major
                    Found in myems-admin/js/angular/angular-sanitize.js - About 45 mins to fix

                      Avoid deeply nested control flow statements.
                      Open

                                                                  for (i = 0; i < stack.length; i++) {
                                                                      if ( stack[ i ].indent != m[1] ) continue;
                                                                      list = stack[ i ].list;
                                                                      stack.splice( i+1 );
                                                                      found = true;
                      Severity: Major
                      Found in myems-admin/js/plugins/bootstrap-markdown/markdown.js - About 45 mins to fix

                        Function interceptor has 6 arguments (exceeds 4 allowed). Consider refactoring.
                        Open

                            var interceptor = ['$q', '$cacheFactory', '$timeout', '$rootScope', '$log', 'cfpLoadingBar', function ($q, $cacheFactory, $timeout, $rootScope, $log, cfpLoadingBar) {
                        Severity: Minor
                        Found in myems-admin/js/plugins/angular-loading-bar/loading-bar.js - About 45 mins to fix

                          Function value has 6 arguments (exceeds 4 allowed). Consider refactoring.
                          Open

                              value: function createThumbnail(file, width, height, resizeMethod, fixOrientation, callback) {
                          Severity: Minor
                          Found in myems-admin/js/plugins/dropzone/dropzone.js - About 45 mins to fix

                            Avoid deeply nested control flow statements.
                            Open

                                                                        if (!found) {
                                                                            //print("not found. l:", uneval(l));
                                                                            wanted_depth++;
                                                                            if (wanted_depth <= stack.length) {
                                                                                stack.splice(wanted_depth);
                            Severity: Major
                            Found in myems-admin/js/plugins/bootstrap-markdown/markdown.js - About 45 mins to fix

                              Avoid deeply nested control flow statements.
                              Open

                                                  if (angular.equals(sCopy, s)) {
                                                    chartSeries.addPoint(ptNew, false);
                                                  }
                                                  
                                                  // Check if the data change was a push and shift operation
                              Severity: Major
                              Found in myems-admin/js/angular-highcharts/highcharts-ng.js - About 45 mins to fix

                                Avoid deeply nested control flow statements.
                                Open

                                                                if ( --open_parens == 0) {
                                                                    consumed -= url.length - len;
                                                                    url = url.substring(0, len);
                                                                }
                                Severity: Major
                                Found in myems-admin/js/plugins/bootstrap-markdown/markdown.js - About 45 mins to fix

                                  Function open has 6 arguments (exceeds 4 allowed). Consider refactoring.
                                  Open

                                                      infoWindow.open = function open(a1, a2, a3, a4, a5, a6) {
                                  Severity: Minor
                                  Found in myems-admin/js/plugins/uimaps/ui-map.js - About 45 mins to fix

                                    Function _typeof has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                                    Open

                                    function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
                                    Severity: Minor
                                    Found in myems-admin/js/plugins/dropzone/dropzone.js - About 45 mins 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 buildChartDirective has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                                    Open

                                    var buildChartDirective = function ( chartType ) {
                                        return {
                                            restrict: 'E',
                                            scope: {
                                                data: "=",
                                    Severity: Minor
                                    Found in myems-admin/js/plugins/peity/angular-peity.js - About 45 mins 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

                                    Avoid deeply nested control flow statements.
                                    Open

                                                else if (c == '{') {
                                                    date = date2;
                                                    otherDate = date1;
                                                }
                                                else if (c == '}') {
                                    Severity: Major
                                    Found in myems-admin/js/plugins/fullcalendar/fullcalendar.min.js - About 45 mins to fix
                                      Severity
                                      Category
                                      Status
                                      Source
                                      Language