sahat/satellizer

View on GitHub

Showing 562 of 562 total issues

Avoid deeply nested control flow statements.
Open

            if (!self.__enableScrollX && self.__refreshHeight != null) {

              // hide the refresher when it's behind the header bar in case of header transparency
              if (scrollTop < 0) {
                self.__refreshHidden = false;
Severity: Major
Found in examples/ionic/www/lib/ionic/js/ionic.js - About 45 mins to fix

    Avoid deeply nested control flow statements.
    Open

          } else if (version == 7) {
            //iPhone == 7.0 WebView
            viewportProperties.height = DEVICE_HEIGHT;
          }
    Severity: Major
    Found in examples/ionic/www/lib/ionic/js/ionic.js - About 45 mins to fix

      Avoid deeply nested control flow statements.
      Open

                } else if (scrollTop > maxScrollTop) {
      
                  scrollTop = maxScrollTop;
      
                } else {
      Severity: Major
      Found in examples/ionic/www/lib/ionic/js/ionic.js - About 45 mins to fix

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

            start: function(stepCallback, verifyCallback, completedCallback, duration, easingMethod, root) {
        Severity: Minor
        Found in examples/ionic/www/lib/ionic/js/ionic.js - About 45 mins to fix

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

                    if (scope) {
                      scope.$emit('$ionicView.' + step + 'Enter', enteringData);
                      if (step == 'after') {
                        scope.$emit('$ionicView.enter', enteringData);
                      }
          Severity: Minor
          Found in examples/ionic/www/lib/ionic/js/ionic-angular.js and 1 other location - About 45 mins to fix
          examples/ionic/www/lib/ionic/js/ionic-angular.js on lines 4718..4723

          Duplicated Code

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

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

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

          Tuning

          This issue has a mass of 50.

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

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

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

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

          Refactorings

          Further Reading

          Avoid deeply nested control flow statements.
          Open

                      if (!self.__refreshActive) {
                        self.__startDeceleration(timeStamp);
                      }
          Severity: Major
          Found in examples/ionic/www/lib/ionic/js/ionic.js - About 45 mins to fix

            Avoid deeply nested control flow statements.
            Open

                      if (handler.comment) handler.comment(html.substring(4, index));
            Severity: Major
            Found in examples/ionic/www/lib/ionic/js/angular/angular-sanitize.js - About 45 mins to fix

              Avoid deeply nested control flow statements.
              Open

                      if (match) {
                        html = html.replace(match[0], '');
                        chars = false;
                      }
              Severity: Major
              Found in examples/ionic/www/lib/ionic/js/angular/angular-sanitize.js - About 45 mins to fix

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

                            var exchangeForTokenUrl = this.SatellizerConfig.baseUrl ? joinUrl(this.SatellizerConfig.baseUrl, this.defaults.url) : this.defaults.url;
                Severity: Major
                Found in examples/ionic/www/lib/satellizer/dist/satellizer.js and 2 other locations - About 45 mins to fix
                examples/ionic/www/lib/satellizer/dist/satellizer.js on lines 672..672
                examples/ionic/www/lib/satellizer/dist/satellizer.js on lines 773..775

                Duplicated Code

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

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

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

                Tuning

                This issue has a mass of 50.

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

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

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

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

                Refactorings

                Further Reading

                Avoid deeply nested control flow statements.
                Open

                          if (isArray(encoded)) {
                            result += map(encoded, encodeDashes).join("-");
                          } else {
                            result += encodeURIComponent(encoded);
                          }
                Severity: Major
                Found in examples/ionic/www/lib/ionic/js/angular-ui/angular-ui-router.js - About 45 mins to fix

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

                      rectContains: function(x, y, x1, y1, x2, y2) {
                  Severity: Minor
                  Found in examples/ionic/www/lib/ionic/js/ionic.js - About 45 mins to fix

                    Avoid deeply nested control flow statements.
                    Open

                              if (forwardView && currentView.stateId !== forwardView.stateId &&
                                 currentView.historyId === forwardView.historyId) {
                                // they navigated to a new view but the stack already has a forward view
                                // since its a new view remove any forwards that existed
                                tmp = getHistoryById(forwardView.historyId);
                    Severity: Major
                    Found in examples/ionic/www/lib/ionic/js/ionic-angular.js - About 45 mins to fix

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

                        self.render = function(registerData, viewLocals, enteringView, leavingView, renderStart, renderEnd) {
                      Severity: Minor
                      Found in examples/ionic/www/lib/ionic/js/ionic-angular.js - About 45 mins to fix

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

                                widthScale = Math.max(self.__indicatorX.minScale,
                                    (self.__indicatorX.size - widthDiff) / self.__indicatorX.size);
                        Severity: Minor
                        Found in examples/ionic/www/lib/ionic/js/ionic.js and 1 other location - About 45 mins to fix
                        examples/ionic/www/lib/ionic/js/ionic.js on lines 5547..5547

                        Duplicated Code

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

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

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

                        Tuning

                        This issue has a mass of 50.

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

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

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

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

                        Refactorings

                        Further Reading

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

                                heightScale = Math.max(self.__indicatorY.minScale, (self.__indicatorY.size - heightDiff) / self.__indicatorY.size);
                        Severity: Minor
                        Found in examples/ionic/www/lib/ionic/js/ionic.js and 1 other location - About 45 mins to fix
                        examples/ionic/www/lib/ionic/js/ionic.js on lines 5499..5500

                        Duplicated Code

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

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

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

                        Tuning

                        This issue has a mass of 50.

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

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

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

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

                        Refactorings

                        Further Reading

                        Avoid deeply nested control flow statements.
                        Open

                                  for (y = 0; y < splitClasses.length; y++) {
                                    cssClass = splitClasses[y].trim();
                                    if (existingClasses.indexOf(' ' + cssClass + ' ') === -1) {
                                      existingClasses += cssClass + ' ';
                                    }
                        Severity: Major
                        Found in examples/ionic/www/lib/ionic/js/ionic-angular.js - About 45 mins to fix

                          Avoid deeply nested control flow statements.
                          Open

                                    for (y = 0; y < splitClasses.length; y++) {
                                      cssClass = splitClasses[y];
                                      el.setAttribute('class', (
                                          (" " + (el.getAttribute('class') || '') + " ")
                                          .replace(/[\n\t]/g, " ")
                          Severity: Major
                          Found in examples/ionic/www/lib/ionic/js/ionic-angular.js - About 45 mins to fix

                            Avoid deeply nested control flow statements.
                            Open

                                    if (initHeight) viewportProperties.height = '0';
                            Severity: Major
                            Found in examples/ionic/www/lib/ionic/js/ionic.js - About 45 mins to fix

                              Avoid deeply nested control flow statements.
                              Open

                                      if (initHeight) viewportProperties.height = '0';
                              Severity: Major
                              Found in examples/ionic/www/lib/ionic/js/ionic.js - About 45 mins to fix

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

                                            if (scope) {
                                              scope.$emit('$ionicView.' + step + 'Leave', leavingData);
                                              if (step == 'after') {
                                                scope.$emit('$ionicView.leave', leavingData);
                                              }
                                Severity: Minor
                                Found in examples/ionic/www/lib/ionic/js/ionic-angular.js and 1 other location - About 45 mins to fix
                                examples/ionic/www/lib/ionic/js/ionic-angular.js on lines 4709..4714

                                Duplicated Code

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

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

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

                                Tuning

                                This issue has a mass of 50.

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

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

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

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

                                Refactorings

                                Further Reading

                                Severity
                                Category
                                Status
                                Source
                                Language