oplik0/cherrydoor

View on GitHub

Showing 556 of 650 total issues

Function mergeProps has a Cognitive Complexity of 22 (exceeds 5 allowed). Consider refactoring.
Open

function mergeProps(...args) {
    const ret = extend({}, args[0]);
    for (let i = 1; i < args.length; i++) {
            const toMerge = args[i];
            for (const key in toMerge) {
Severity: Minor
Found in cherrydoor/static/js/vue-dev.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 getSequence has a Cognitive Complexity of 22 (exceeds 5 allowed). Consider refactoring.
Open

function getSequence(arr) {
    const p = arr.slice();
    const result = [0];
    let i, j, u, v, c;
    const len = arr.length;
Severity: Minor
Found in cherrydoor/static/js/vue-dev.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 fillValues has 76 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    fillValues: function fillValues(forceEmit) {
      var _this9 = this;

      var fullValues = {};
      var baseHour = this.hour;
Severity: Major
Found in cherrydoor/static/components/VueTimepicker.js - About 3 hrs to fix

    Function extractComponentsGuards has 74 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    function extractComponentsGuards(matched, guardType, to, from) {
        const guards = [];
        for (const record of matched) {
            for (const name in record.components) {
                let rawComponent = record.components[name];
    Severity: Major
    Found in cherrydoor/static/js/vue-router.js - About 2 hrs to fix

      Function 7dd0 has 74 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

      /***/ (function(module, exports, __webpack_require__) {
      
      "use strict";
      
      var $ = __webpack_require__("23e7");
      Severity: Major
      Found in cherrydoor/static/components/VueTimepicker.js - About 2 hrs to fix

        Function resolvePropValue has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring.
        Open

        function resolvePropValue(options, props, key, value, instance, isAbsent) {
            const opt = options[key];
            if (opt != null) {
                    const hasDefault = hasOwn(opt, 'default');
                    // default values
        Severity: Minor
        Found in cherrydoor/static/js/vue-dev.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 traverseStaticChildren has a Cognitive Complexity of 21 (exceeds 5 allowed). Consider refactoring.
        Open

        function traverseStaticChildren(n1, n2, shallow = false) {
            const ch1 = n1.children;
            const ch2 = n2.children;
            if (isArray(ch1) && isArray(ch2)) {
                    for (let i = 0; i < ch1.length; i++) {
        Severity: Minor
        Found in cherrydoor/static/js/vue-dev.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 pushWithRedirect has 72 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            function pushWithRedirect(to, redirectedFrom) {
                const targetLocation = (pendingLocation = resolve(to));
                const from = currentRoute.value;
                const data = to.state;
                const force = to.force;
        Severity: Major
        Found in cherrydoor/static/js/vue-router.js - About 2 hrs to fix

          Function setup has 71 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

              setup(props, { attrs, slots }) {
                  warnDeprecatedUsage();
                  const injectedRoute = inject(routerViewLocationKey);
                  const routeToDisplay = computed(() => props.route || injectedRoute.value);
                  const depth = inject(viewDepthKey, 0);
          Severity: Major
          Found in cherrydoor/static/js/vue-router.js - About 2 hrs to fix

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

            function trigger(target, type, key, newValue, oldValue, oldTarget) {
                const depsMap = targetMap.get(target);
                if (!depsMap) {
                        // never been tracked
                        return;
            Severity: Major
            Found in cherrydoor/static/js/vue-dev.js - About 2 hrs to fix

              Function addRoute has 71 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  function addRoute(record, parent, originalRecord) {
                      // used later on to remove by name
                      let isRootAdd = !originalRecord;
                      let mainNormalizedRecord = normalizeRouteRecord(record);
                      // we might be the child of an alias
              Severity: Major
              Found in cherrydoor/static/js/vue-router.js - About 2 hrs to fix

                Function generate has 71 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                function generate(ast, options = {}) {
                    const context = createCodegenContext(ast, options);
                    if (options.onContextCreated)
                            options.onContextCreated(context);
                    const { mode, push, prefixIdentifiers, indent, deindent, newline, scopeId, ssr } = context;
                Severity: Major
                Found in cherrydoor/static/js/vue-dev.js - About 2 hrs to fix

                  Function get has 71 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                      get({ _: instance }, key) {
                              const { ctx, setupState, data, props, accessCache, type, appContext } = instance;
                              // let @vue/reactivity know it should never observe Vue public instances.
                              if (key === "__v_skip" /* SKIP */) {
                                      return true;
                  Severity: Major
                  Found in cherrydoor/static/js/vue-dev.js - About 2 hrs to fix

                    Function setup has 69 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                        setup(props, { slots }) {
                                const instance = getCurrentInstance();
                                const state = useTransitionState();
                                let prevTransitionKey;
                                return () => {
                    Severity: Major
                    Found in cherrydoor/static/js/vue-dev.js - About 2 hrs to fix

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

                      function setupStatefulComponent(instance, isSSR) {
                          const Component = instance.type;
                          {
                                  if (Component.name) {
                                          validateComponentName(Component.name, instance.appContext.config);
                      Severity: Minor
                      Found in cherrydoor/static/js/vue-dev.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 updateSlots has a Cognitive Complexity of 20 (exceeds 5 allowed). Consider refactoring.
                      Open

                      const updateSlots = (instance, children, optimized) => {
                          const { vnode, slots } = instance;
                          let needDeletionCheck = true;
                          let deletionComparisonTarget = EMPTY_OBJ;
                          if (vnode.shapeFlag & 32 /* SLOTS_CHILDREN */) {
                      Severity: Minor
                      Found in cherrydoor/static/js/vue-dev.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 patchStyle has a Cognitive Complexity of 20 (exceeds 5 allowed). Consider refactoring.
                      Open

                      function patchStyle(el, prev, next) {
                          const style = el.style;
                          if (!next) {
                                  el.removeAttribute('style');
                          }
                      Severity: Minor
                      Found in cherrydoor/static/js/vue-dev.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 transformFor has 68 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                      const transformFor = createStructuralDirectiveTransform('for', (node, dir, context) => {
                          const { helper, removeHelper } = context;
                          return processFor(node, dir, context, forNode => {
                                  // create the loop render function expression now, and add the
                                  // iterator on exit after all children have been traversed
                      Severity: Major
                      Found in cherrydoor/static/js/vue-dev.js - About 2 hrs to fix

                        Function process has 67 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                            process(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, internals) {
                                    const { mc: mountChildren, pc: patchChildren, pbc: patchBlockChildren, o: { insert, querySelector, createText, createComment } } = internals;
                                    const disabled = isTeleportDisabled(n2.props);
                                    let { shapeFlag, children, dynamicChildren } = n2;
                                    // #3302
                        Severity: Major
                        Found in cherrydoor/static/js/vue-dev.js - About 2 hrs to fix

                          Function 4d63 has 67 lines of code (exceeds 25 allowed). Consider refactoring.
                          Open

                          /***/ (function(module, exports, __webpack_require__) {
                          
                          var DESCRIPTORS = __webpack_require__("83ab");
                          var global = __webpack_require__("da84");
                          var isForced = __webpack_require__("94ca");
                          Severity: Major
                          Found in cherrydoor/static/components/VueTimepicker.js - About 2 hrs to fix
                            Severity
                            Category
                            Status
                            Source
                            Language