Showing 398 of 398 total issues

Avoid deeply nested control flow statements.
Open

                            if (!this.match(',')) {
                                break;
                            }
Severity: Major
Found in dist/csp.tmpl.js - About 45 mins to fix

    Avoid deeply nested control flow statements.
    Open

                                    if (this.source[this.index] === '{') {
                                        ++this.index;
                                        str += this.scanUnicodeCodePointEscape();
                                    }
                                    else {
    Severity: Major
    Found in dist/csp.tmpl.js - About 45 mins to fix

      Avoid deeply nested control flow statements.
      Open

              if (~beforeReWords.indexOf(code.slice(pos + 1, end))) {
                start = next;
              }
      Severity: Major
      Found in dist/csp.tmpl.js - About 45 mins to fix

        Avoid deeply nested control flow statements.
        Open

                                    if (this.scanner.isStrictModeReservedWord(id.name)) {
                                        this.tolerateUnexpectedToken(token, messages_1.Messages.StrictReservedWord);
                                    }
        Severity: Major
        Found in dist/csp.tmpl.js - About 45 mins to fix

          Avoid deeply nested control flow statements.
          Open

                                  if (declarations.length === 1 && declarations[0].init === null && this.matchKeyword('in')) {
                                      init = this.finalize(init, new Node.VariableDeclaration(declarations, kind));
                                      this.nextToken();
                                      left = init;
                                      right = this.parseExpression();
          Severity: Major
          Found in dist/csp.tmpl.js - About 45 mins to fix

            Avoid deeply nested control flow statements.
            Open

                                    if (this.trackComment) {
                                        loc.end = {
                                            line: this.lineNumber,
                                            column: this.index - this.lineStart
                                        };
            Severity: Major
            Found in dist/csp.tmpl.js - About 45 mins to fix

              Avoid deeply nested control flow statements.
              Open

                                          if (this.match('...')) {
                                              if (!this.context.isBindingElement) {
                                                  this.throwUnexpectedToken(this.lookahead);
                                              }
                                              expressions.push(this.parseRestElement(params));
              Severity: Major
              Found in dist/csp.tmpl.js - About 45 mins to fix

                Avoid deeply nested control flow statements.
                Open

                        while (--pos >= 0 && RE_VN_CHAR.test(code[pos]));
                Severity: Major
                Found in dist/csp.tmpl.js - About 45 mins to fix

                  Avoid deeply nested control flow statements.
                  Open

                          while (--pos >= 0 && RE_VN_CHAR.test(code[pos]));
                  Severity: Major
                  Found in src/skip-regex.js - About 45 mins to fix

                    Avoid deeply nested control flow statements.
                    Open

                              if (~beforeReWords.indexOf(code.slice(pos + 1, end))) {
                                start = next
                              }
                    Severity: Major
                    Found in dist/tmpl.js - About 45 mins to fix

                      Avoid deeply nested control flow statements.
                      Open

                              if (~beforeReWords.indexOf(code.slice(pos + 1, end))) {
                                start = next
                              }
                      Severity: Major
                      Found in src/skip-regex.js - About 45 mins to fix

                        Avoid deeply nested control flow statements.
                        Open

                                      if (match[1]) {
                                        if (match[1] === ch) ++ix
                                        else if (!--ix) break
                                      } else {
                                        rech.lastIndex = pushQBlock(match.index, rech.lastIndex, match[2])
                        Severity: Major
                        Found in dist/tmpl.js - About 45 mins to fix

                          Avoid deeply nested control flow statements.
                          Open

                                        if (r instanceof ReturnValue){ // break out
                                          if (r.type == 'break') break
                                          result = r
                                        }
                          Severity: Major
                          Found in src/notevil/index.js - About 45 mins to fix

                            Avoid deeply nested control flow statements.
                            Open

                                      while (--pos >= 0 && RE_VN_CHAR.test(code[pos]));
                            Severity: Major
                            Found in dist/tmpl.js - About 45 mins to fix

                              Avoid deeply nested control flow statements.
                              Open

                                          if (match[1]) {
                                            if (match[1] === ch) ++ix
                                            else if (!--ix) break
                                          } else {
                                            rech.lastIndex = pushQBlock(match.index, rech.lastIndex, match[2])
                              Severity: Major
                              Found in src/brackets.js - About 45 mins to fix

                                Identical blocks of code found in 2 locations. Consider refactoring.
                                Open

                                            var msg = messageFormat.replace(/%(\d)/g, function (whole, idx) {
                                                assert_1.assert(idx < args.length, 'Message reference must be in range');
                                                return args[idx];
                                            });
                                Severity: Minor
                                Found in dist/csp.tmpl.js and 1 other location - About 45 mins to fix
                                dist/csp.tmpl.js on lines 646..649

                                Duplicated Code

                                Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                                Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                                When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                                Tuning

                                This issue has a mass of 50.

                                We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                                The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                                If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                                See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                                Refactorings

                                Further Reading

                                Similar blocks of code found in 2 locations. Consider refactoring.
                                Open

                                            return this.matchJSX('{') ? this.parseJSXExpressionAttribute() :
                                                this.matchJSX('<') ? this.parseJSXElement() : this.parseJSXStringLiteralAttribute();
                                Severity: Minor
                                Found in dist/csp.tmpl.js and 1 other location - About 45 mins to fix
                                dist/csp.tmpl.js on lines 3366..3367

                                Duplicated Code

                                Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                                Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                                When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                                Tuning

                                This issue has a mass of 50.

                                We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                                The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                                If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                                See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                                Refactorings

                                Further Reading

                                Identical blocks of code found in 2 locations. Consider refactoring.
                                Open

                                            var msg = messageFormat.replace(/%(\d)/g, function (whole, idx) {
                                                assert_1.assert(idx < args.length, 'Message reference must be in range');
                                                return args[idx];
                                            });
                                Severity: Minor
                                Found in dist/csp.tmpl.js and 1 other location - About 45 mins to fix
                                dist/csp.tmpl.js on lines 631..634

                                Duplicated Code

                                Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                                Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                                When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                                Tuning

                                This issue has a mass of 50.

                                We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                                The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                                If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                                See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                                Refactorings

                                Further Reading

                                Similar blocks of code found in 2 locations. Consider refactoring.
                                Open

                                                    var declaration = this.match('{') ? this.parseObjectInitializer() :
                                                        this.match('[') ? this.parseArrayInitializer() : this.parseAssignmentExpression();
                                Severity: Minor
                                Found in dist/csp.tmpl.js and 1 other location - About 45 mins to fix
                                dist/csp.tmpl.js on lines 5829..5830

                                Duplicated Code

                                Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                                Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                                When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                                Tuning

                                This issue has a mass of 50.

                                We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                                The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                                If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                                See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                                Refactorings

                                Further Reading

                                Identical blocks of code found in 2 locations. Consider refactoring.
                                Open

                                Primitives.prototype.getPropertyObject = function (object, property) {
                                  if (immutable[typeof object]) {
                                    return this.getPrototypeOf(object)
                                  }
                                  return object
                                Severity: Minor
                                Found in dist/csp.tmpl.js and 1 other location - About 40 mins to fix
                                src/notevil/lib/primitives.js on lines 38..43

                                Duplicated Code

                                Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                                Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                                When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                                Tuning

                                This issue has a mass of 49.

                                We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                                The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                                If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                                See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                                Refactorings

                                Further Reading

                                Severity
                                Category
                                Status
                                Source
                                Language