zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js

Summary

Maintainability
F
1 mo
Test Coverage

File zk-3913-PDF417lib.js has 1305 lines of code (exceeds 250 allowed). Consider refactoring.
Open

/*The MIT License (MIT)

Copyright (c) 2014 James Liu j@jamesliu.info
*/

Severity: Major
Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 3 days to fix

    Function getCompaction has a Cognitive Complexity of 60 (exceeds 5 allowed). Consider refactoring.
    Open

        getCompaction: function(a, b, c) {
            c = c || !0;
            var d = [];
            switch (a) {
                case 900:
    Severity: Minor
    Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 1 day 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 bc_divide has a Cognitive Complexity of 53 (exceeds 5 allowed). Consider refactoring.
    Open

        bc_divide: function(a, b, c) {
            var d, e, g, f, h, k, l, m, n, q, s, p, r, t;
            if (libbcmath.bc_is_zero(b)) return -1;
            if (libbcmath.bc_is_zero(a)) return libbcmath.bc_new_num(1, c);
            0 === b.n_scale && 1 === b.n_len && 1 === b.n_value[0] && (d = libbcmath.bc_new_num(
    Severity: Minor
    Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 1 day 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 _bc_do_compare has a Cognitive Complexity of 50 (exceeds 5 allowed). Consider refactoring.
    Open

        _bc_do_compare: function(a, b, c, d) {
            var e, g, f;
            if (c && a.n_sign != b.n_sign) return a.n_sign == libbcmath.PLUS ? 1 : -1;
            if (a.n_len != b.n_len) return a.n_len > b.n_len ? c && a.n_sign !=
                libbcmath.PLUS ? -1 : 1 : c && a.n_sign != libbcmath.PLUS ? 1 : -1;
    Severity: Minor
    Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 7 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 init has a Cognitive Complexity of 28 (exceeds 5 allowed). Consider refactoring.
    Open

        init: function(a, b, c) {
            a = unescape(encodeURIComponent(a));
            b = b || -1;
            c = c || 2;
            this.barcode_array = {};
    Severity: Minor
    Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 4 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 _sprintf has 95 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        _sprintf: function() {
            var a = arguments,
                b = 0,
                c = function(a, b, c, d) {
                    c || (c = " ");
    Severity: Major
    Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 3 hrs to fix

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

          getInputSequences: function(a) {
              var b = [],
                  c = [],
                  c = a.match(/([0-9]{13,44})/g);
              if (null == c) c = [];
      Severity: Minor
      Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.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 _bc_shift_addsub has a Cognitive Complexity of 23 (exceeds 5 allowed). Consider refactoring.
      Open

      libbcmath._bc_shift_addsub = function(a, b, c, d) {
          var e, g, f;
          g = b.n_len;
          0 === b.n_value[0] && g--;
          if (!(a.n_len + a.n_scale >= c + g)) throw Error(
      Severity: Minor
      Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.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 _bc_do_add has a Cognitive Complexity of 23 (exceeds 5 allowed). Consider refactoring.
      Open

          _bc_do_add: function(a, b, c) {
              var d, e, g, f, h, k, l;
              d = libbcmath.MAX(a.n_scale, b.n_scale);
              e = libbcmath.MAX(a.n_len, b.n_len) + 1;
              c = libbcmath.bc_new_num(e,
      Severity: Minor
      Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.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 init has 73 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          init: function(a, b, c) {
              a = unescape(encodeURIComponent(a));
              b = b || -1;
              c = c || 2;
              this.barcode_array = {};
      Severity: Major
      Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 2 hrs to fix

        libbcmath has 25 functions (exceeds 20 allowed). Consider refactoring.
        Open

        var libbcmath = {
            PLUS: "+",
            MINUS: "-",
            BASE: 10,
            scale: 0,
        Severity: Minor
        Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 2 hrs to fix

          Function _array_search has a Cognitive Complexity of 20 (exceeds 5 allowed). Consider refactoring.
          Open

              _array_search: function(a, b, c) {
                  var d = !!c,
                      e = "";
                  if (b && "object" === typeof b && b.change_key_case) return b.search(a, c);
                  if ("object" === typeof a && a.exec) {
          Severity: Minor
          Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 2 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 getErrorCorrectionLevel has a Cognitive Complexity of 18 (exceeds 5 allowed). Consider refactoring.
          Open

              getErrorCorrectionLevel: function(a, b) {
                  for (var c = 8, d = 928 - b; 0 < c && !(d >= 2 << a);) --c;
                  if (0 > a || 8 < a) a = 41 > b ? 2 : 161 > b ? 3 : 321 > b ? 4 : 864 > b ?
                      5 : c;
                  a > c && (a = c);
          Severity: Minor
          Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 2 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 getCompaction has 58 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

              getCompaction: function(a, b, c) {
                  c = c || !0;
                  var d = [];
                  switch (a) {
                      case 900:
          Severity: Major
          Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 2 hrs to fix

            Function bc_divide has 58 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                bc_divide: function(a, b, c) {
                    var d, e, g, f, h, k, l, m, n, q, s, p, r, t;
                    if (libbcmath.bc_is_zero(b)) return -1;
                    if (libbcmath.bc_is_zero(a)) return libbcmath.bc_new_num(1, c);
                    0 === b.n_scale && 1 === b.n_len && 1 === b.n_value[0] && (d = libbcmath.bc_new_num(
            Severity: Major
            Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 2 hrs to fix

              Function _bc_do_sub has a Cognitive Complexity of 17 (exceeds 5 allowed). Consider refactoring.
              Open

                  _bc_do_sub: function(a, b, c) {
                      var d, e, g, f, h, k, l, m, n;
                      e = libbcmath.MAX(a.n_len, b.n_len);
                      d = libbcmath.MAX(a.n_scale, b.n_scale);
                      f = libbcmath.MIN(a.n_len, b.n_len);
              Severity: Minor
              Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 2 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 _preg_split has a Cognitive Complexity of 16 (exceeds 5 allowed). Consider refactoring.
              Open

                  _preg_split: function(a, b, c, d) {
                      c = c || 0;
                      d = d || "";
                      var e, g = [],
                          f = 0,
              Severity: Minor
              Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 2 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 _preg_split has 47 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  _preg_split: function(a, b, c, d) {
                      c = c || 0;
                      d = d || "";
                      var e, g = [],
                          f = 0,
              Severity: Minor
              Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 1 hr to fix

                Function bc_str2num has a Cognitive Complexity of 14 (exceeds 5 allowed). Consider refactoring.
                Open

                    bc_str2num: function(a, b) {
                        var c, d, e, g, f, h, k;
                        c = a.split("");
                        f = g = e = 0;
                        h = !1;
                Severity: Minor
                Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 1 hr 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 getInputSequences has 36 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                    getInputSequences: function(a) {
                        var b = [],
                            c = [],
                            c = a.match(/([0-9]{13,44})/g);
                        if (null == c) c = [];
                Severity: Minor
                Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 1 hr to fix

                  Function _bc_rec_mul has 35 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                  libbcmath._bc_rec_mul = function(a, b, c, d, e) {
                      var g, f, h, k, l, m, n;
                      if (b + d < libbcmath.MUL_BASE_DIGITS || b < libbcmath.MUL_SMALL_DIGITS || d <
                          libbcmath.MUL_SMALL_DIGITS) return libbcmath._bc_simp_mul(a, b, c, d, e);
                      e = Math.floor((libbcmath.MAX(b, d) + 1) / 2);
                  Severity: Minor
                  Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 1 hr to fix

                    Function _sprintf has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring.
                    Open

                        _sprintf: function() {
                            var a = arguments,
                                b = 0,
                                c = function(a, b, c, d) {
                                    c || (c = " ");
                    Severity: Minor
                    Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 1 hr 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 _intval has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring.
                    Open

                        _intval: function(a, b) {
                            var c;
                            c = typeof a;
                            return "boolean" ===
                                c ? +a : "string" === c ? (c = parseInt(a, b || 10), isNaN(c) || !isFinite(
                    Severity: Minor
                    Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 1 hr 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 _bc_do_add has 30 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                        _bc_do_add: function(a, b, c) {
                            var d, e, g, f, h, k, l;
                            d = libbcmath.MAX(a.n_scale, b.n_scale);
                            e = libbcmath.MAX(a.n_len, b.n_len) + 1;
                            c = libbcmath.bc_new_num(e,
                    Severity: Minor
                    Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 1 hr to fix

                      Consider simplifying this complex logical expression.
                      Open

                                                  if (m != e && !1 !== (l = this._array_search(k, this.textsubmodes[m]))) {
                                                      (h + 1 == f || h + 1 < f && !1 !== this._array_search(this._ord(b.charAt(
                                                          h + 1)), this.textsubmodes[e])) && (3 == m || 0 == m && 1 == e) ? 3
                                                          == m ? g.push(29) : g.push(27): (g = g.concat(this.textlatch["" + e +
                                                              m]), e = m);
                      Severity: Major
                      Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 1 hr to fix

                        Function e has 7 arguments (exceeds 4 allowed). Consider refactoring.
                        Open

                                    e = function(a, b, e, k, l, m, n) {
                        Severity: Major
                        Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 50 mins to fix

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

                                      d = function(a, b, d, e, l, m) {
                          Severity: Minor
                          Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 45 mins to fix

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

                                _one_mult: function(a, b, c, d, e, g) {
                            Severity: Minor
                            Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 45 mins to fix

                              Avoid deeply nested control flow statements.
                              Open

                                                          if (m != e && !1 !== (l = this._array_search(k, this.textsubmodes[m]))) {
                                                              (h + 1 == f || h + 1 < f && !1 !== this._array_search(this._ord(b.charAt(
                                                                  h + 1)), this.textsubmodes[e])) && (3 == m || 0 == m && 1 == e) ? 3
                                                                  == m ? g.push(29) : g.push(27): (g = g.concat(this.textlatch["" + e +
                                                                      m]), e = m);
                              Severity: Major
                              Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 45 mins to fix

                                Consider simplifying this complex logical expression.
                                Open

                                            if (0 < f[1]) {
                                                var k = a.substr(e, f[1] - e),
                                                    l = [],
                                                    l = k.match(/([\x09\x0a\x0d\x20-\x7e]{5,})/g);
                                                if (null == l) l = [];
                                Severity: Major
                                Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 40 mins to fix

                                  Function _bc_simp_mul has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                  Open

                                  libbcmath._bc_simp_mul = function(a, b, c, d, e) {
                                  Severity: Minor
                                  Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 35 mins to fix

                                    Function _bc_rec_mul has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                    Open

                                    libbcmath._bc_rec_mul = function(a, b, c, d, e) {
                                    Severity: Minor
                                    Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 35 mins to fix

                                      Function memcpy has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                      Open

                                          memcpy: function(a, b, c, d, e) {
                                      Severity: Minor
                                      Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 35 mins to fix

                                        Function bc_num has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
                                        Open

                                            bc_num: function() {
                                                this.n_value = this.n_scale = this.n_len = this.n_sign = null;
                                                this.toString = function() {
                                                    var a, b;
                                                    b = this.n_value.join("");
                                        Severity: Minor
                                        Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 35 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 _bc_rec_mul has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
                                        Open

                                        libbcmath._bc_rec_mul = function(a, b, c, d, e) {
                                            var g, f, h, k, l, m, n;
                                            if (b + d < libbcmath.MUL_BASE_DIGITS || b < libbcmath.MUL_SMALL_DIGITS || d <
                                                libbcmath.MUL_SMALL_DIGITS) return libbcmath._bc_simp_mul(a, b, c, d, e);
                                            e = Math.floor((libbcmath.MAX(b, d) + 1) / 2);
                                        Severity: Minor
                                        Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 35 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 too many return statements within this function.
                                        Open

                                                return 0
                                        Severity: Major
                                        Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 30 mins to fix

                                          Avoid too many return statements within this function.
                                          Open

                                                  return !1
                                          Severity: Major
                                          Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 30 mins to fix

                                            Avoid too many return statements within this function.
                                            Open

                                                                if (0 !== a.n_value[e++]) return c && a.n_sign != libbcmath.PLUS ? -1 :
                                                                    1
                                            Severity: Major
                                            Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 30 mins to fix

                                              Avoid too many return statements within this function.
                                              Open

                                                                      if (0 !== b.n_value[g++]) return c && a.n_sign != libbcmath.PLUS ? 1 :
                                                                          -1;
                                              Severity: Major
                                              Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 30 mins to fix

                                                Function _array_fill has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
                                                Open

                                                    _array_fill: function(a, b, c) {
                                                        var d, e = {};
                                                        if (0 == a) {
                                                            a = [];
                                                            for (d = 0; d < b; d++) a.push(c);
                                                Severity: Minor
                                                Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 25 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 bc_sub has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
                                                Open

                                                libbcmath.bc_sub = function(a, b, c) {
                                                    var d, e;
                                                    if (a.n_sign != b.n_sign) d = libbcmath._bc_do_add(a, b, c), d.n_sign = a.n_sign;
                                                    else switch (e = libbcmath._bc_do_compare(a, b, !1, !1), e) {
                                                        case -1:
                                                Severity: Minor
                                                Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js - About 25 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

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

                                                        [128352, 129720, 125504, 128304, 129692, 125472, 128280, 129678, 125456,
                                                            128268, 125448, 128262, 125444, 125792, 128440, 129758, 120384, 125744,
                                                            128412, 120352, 125720, 128398, 120336, 125708, 120328, 125702, 120324,
                                                            120672, 125880, 128478, 110144, 120624, 125852, 110112, 120600, 125838,
                                                            110096, 120588, 110088, 120582, 110084,
                                                Severity: Major
                                                Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js and 2 other locations - About 5 days to fix
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 533..634
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 739..837

                                                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 931.

                                                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 3 locations. Consider refactoring.
                                                Open

                                                        [109536, 120312, 86976, 109040, 120060, 86496, 108792, 119934, 86256,
                                                            108668, 86136, 129744, 89056, 110072, 129736, 88560, 109820, 129732, 88312,
                                                            109694,
                                                            129730, 88188, 128464, 129772, 89592, 128456, 129766, 89340, 128452, 89214,
                                                            128450, 125904, 128492, 125896, 128486, 125892, 125890, 120784, 125932,
                                                Severity: Major
                                                Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js and 2 other locations - About 5 days to fix
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 533..634
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 635..738

                                                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 931.

                                                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 3 locations. Consider refactoring.
                                                Open

                                                        [120256, 125680, 128380, 120032, 125560, 128318, 108736, 119920, 108640,
                                                            86080, 108592, 86048, 110016, 120560, 125820, 109792, 120440, 125758,
                                                            88256, 109680, 88160, 89536, 110320, 120700, 89312, 110200, 120638, 89200,
                                                            110140, 89840, 110460, 89720, 110398, 89980, 128506, 119520, 125304,
                                                            128190, 107712, 119408, 125244, 107616, 119352, 84032, 107568, 119324,
                                                Severity: Major
                                                Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js and 2 other locations - About 5 days to fix
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 635..738
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 739..837

                                                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 931.

                                                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 3 locations. Consider refactoring.
                                                Open

                                                function bcadd(a, b, c) {
                                                    "undefined" == typeof c && (c = libbcmath.scale);
                                                    c = 0 > c ? 0 : c;
                                                    libbcmath.bc_init_num();
                                                    libbcmath.bc_init_num();
                                                Severity: Major
                                                Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js and 2 other locations - About 1 day to fix
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 428..441
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 476..489

                                                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 235.

                                                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 3 locations. Consider refactoring.
                                                Open

                                                function bcmul(a, b, c) {
                                                    "undefined" == typeof c && (c = libbcmath.scale);
                                                    c = 0 > c ? 0 : c;
                                                    libbcmath.bc_init_num();
                                                    libbcmath.bc_init_num();
                                                Severity: Major
                                                Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js and 2 other locations - About 1 day to fix
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 413..426
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 428..441

                                                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 235.

                                                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 3 locations. Consider refactoring.
                                                Open

                                                function bcsub(a, b, c) {
                                                    "undefined" == typeof c && (c = libbcmath.scale);
                                                    c = 0 > c ? 0 : c;
                                                    libbcmath.bc_init_num();
                                                    libbcmath.bc_init_num();
                                                Severity: Major
                                                Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js and 2 other locations - About 1 day to fix
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 413..426
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 476..489

                                                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 235.

                                                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

                                                    d < e ? (k = libbcmath.bc_init_num(), h = libbcmath.new_sub_num(d, 0, c.n_value)) :
                                                        (k = libbcmath.new_sub_num(d - e, 0, c.n_value),
                                                            h = libbcmath.new_sub_num(e, 0, c.n_value + d - e));
                                                Severity: Major
                                                Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js and 1 other location - About 3 hrs to fix
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 362..364

                                                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 96.

                                                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

                                                    b < e ? (f = libbcmath.bc_init_num(), g = libbcmath.new_sub_num(b, 0, a.n_value)) :
                                                        (f = libbcmath.new_sub_num(b - e, 0, a.n_value), g = libbcmath.new_sub_num(e,
                                                            0, a.n_value + b - e));
                                                Severity: Major
                                                Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js and 1 other location - About 3 hrs to fix
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 365..367

                                                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 96.

                                                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

                                                            for (; 0 < k--;) l = b.n_value[f--] + e, l >= libbcmath.BASE ? (e = 1, l -=
                                                                libbcmath.BASE) : e = 0, c.n_value[d--] = l;
                                                Severity: Major
                                                Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js and 1 other location - About 2 hrs to fix
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 262..264

                                                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 82.

                                                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

                                                            for (; 0 < h--;) l = a.n_value[g--] + e, l >= libbcmath.BASE ? (e = 1, l -=
                                                                    libbcmath.BASE) :
                                                                e = 0, c.n_value[d--] = l;
                                                Severity: Major
                                                Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js and 1 other location - About 2 hrs to fix
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 259..260

                                                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 82.

                                                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

                                                        case 0:
                                                            a = libbcmath.MAX(c, libbcmath.MAX(a.n_scale, b.n_scale));
                                                            d = libbcmath.bc_new_num(1, a);
                                                            libbcmath.memset(d.n_value, 0, 0, a + 1);
                                                            break;
                                                Severity: Major
                                                Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js and 1 other location - About 2 hrs to fix
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 129..133

                                                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 76.

                                                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

                                                            case 0:
                                                                a = libbcmath.MAX(c, libbcmath.MAX(a.n_scale, b.n_scale));
                                                                d = libbcmath.bc_new_num(1, a);
                                                                libbcmath.memset(d.n_value, 0, 0, a + 1);
                                                                break;
                                                Severity: Major
                                                Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js and 1 other location - About 2 hrs to fix
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 402..406

                                                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 76.

                                                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

                                                                    p + 2] && (r--, b.n_value[h + 1] * r > 10 * (10 * e[p] + e[p + 1] - b.n_value[
                                                                    h] * r) + e[p + 2] && r--);
                                                Severity: Major
                                                Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js and 1 other location - About 1 hr to fix
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 212..214

                                                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 74.

                                                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

                                                                b.n_value[h + 1] * r > 10 * (10 * e[p] + e[p + 1] - b.n_value[h] * r) + e[
                                                                    p + 2] && (r--, b.n_value[h + 1] * r > 10 * (10 * e[p] + e[p + 1] - b.n_value[
                                                                    h] * r) + e[p + 2] && r--);
                                                Severity: Major
                                                Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js and 1 other location - About 1 hr to fix
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 213..214

                                                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 74.

                                                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

                                                                m = m ? "*" == m ? +a[b++] : "*" == m.charAt(0) ? +a[m.slice(1, -1)] : +
                                                                    m : -1 < "fFeE".indexOf(n) ? 6 : "d" == n ? 0 :
                                                                    void 0;
                                                Severity: Major
                                                Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js and 1 other location - About 1 hr to fix
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 1199..1200

                                                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 57.

                                                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

                                                                k = k ? "*" == k ? +a[b++] : "*" == k.charAt(0) ? +a[k.slice(1, -1)] : +
                                                                    k : 0;
                                                Severity: Major
                                                Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js and 1 other location - About 1 hr to fix
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 1203..1205

                                                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 57.

                                                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

                                                                case 1:
                                                                    k = 30 * this._intval(l / 3) + this._intval((g - 1) / 3);
                                                                    break;
                                                Severity: Minor
                                                Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js and 1 other location - About 40 mins to fix
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 967..970

                                                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 48.

                                                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

                                                                case 0:
                                                                    k =
                                                                        30 * this._intval(l / 3) + this._intval((g - 1) / 3);
                                                                    break;
                                                Severity: Minor
                                                Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js and 1 other location - About 40 mins to fix
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 983..985

                                                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 48.

                                                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

                                                                        do b = this._my_bcmod(h, "900"), h = bcdiv(h, "900"), d.unshift(b); while (
                                                                            "0" != h)
                                                Severity: Minor
                                                Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js and 1 other location - About 30 mins to fix
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 1086..1087

                                                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 45.

                                                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

                                                                    do b = this._my_bcmod(h, "900"), h = bcdiv(h, "900"), d.unshift(b); while (
                                                                        "0" != h);
                                                Severity: Minor
                                                Found in zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js and 1 other location - About 30 mins to fix
                                                zktest/src/main/webapp/test2/js/zk-3913-PDF417lib.js on lines 1074..1075

                                                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 45.

                                                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

                                                There are no issues that match your filters.

                                                Category
                                                Status