sahat/satellizer

View on GitHub

Showing 562 of 562 total issues

Function transformGesture has 43 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    handler: function transformGesture(ev, inst) {
      // current gesture isnt drag, but dragged is true
      // this means an other gesture is busy. now call dragend
      if(ionic.Gestures.detection.current.name != this.name && this.triggered) {
        inst.trigger(this.name + 'end', ev);
Severity: Minor
Found in examples/ionic/www/lib/ionic/js/ionic.js - About 1 hr to fix

    Function viewportUpdate has 43 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    function viewportUpdate() {
      // unit tests in viewport.unit.js
    
      var initWidth = viewportProperties.width;
      var initHeight = viewportProperties.height;
    Severity: Minor
    Found in examples/ionic/www/lib/ionic/js/ionic.js - About 1 hr to fix

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

          var loginRequired = ['$q', '$location', '$auth', function($q, $location, $auth) {
            var deferred = $q.defer();
            if ($auth.isAuthenticated()) {
              deferred.resolve();
            } else {
      Severity: Major
      Found in examples/client/app.js and 1 other location - About 1 hr to fix
      examples/server/php/public/app.js on lines 17..25

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

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

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

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

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

      Refactorings

      Further Reading

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

          var loginRequired = function($q, $location, $auth) {
            var deferred = $q.defer();
            if ($auth.isAuthenticated()) {
              deferred.resolve();
            } else {
      Severity: Major
      Found in examples/server/php/public/app.js and 1 other location - About 1 hr to fix
      examples/client/app.js on lines 17..25

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

      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

          addClass: function() {
            for (var x = 0; x < arguments.length; x++) {
              $document[0].body.classList.add(arguments[x]);
            }
            return this;
      Severity: Major
      Found in examples/ionic/www/lib/ionic/js/ionic-angular.js and 1 other location - About 1 hr to fix
      examples/ionic/www/lib/ionic/js/ionic-angular.js on lines 467..472

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

      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

          removeClass: function() {
            for (var x = 0; x < arguments.length; x++) {
              $document[0].body.classList.remove(arguments[x]);
            }
            return this;
      Severity: Major
      Found in examples/ionic/www/lib/ionic/js/ionic-angular.js and 1 other location - About 1 hr to fix
      examples/ionic/www/lib/ionic/js/ionic-angular.js on lines 454..459

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

      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

      Function showPopup has 42 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

        function showPopup(options) {
          var popup = $ionicPopup._createPopup(options);
          var showDelay = 0;
      
          if (popupStack.length > 0) {
      Severity: Minor
      Found in examples/ionic/www/lib/ionic/js/ionic-angular.js - About 1 hr to fix

        Function compile has 42 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            compile: function(tElement) {
              //We cannot use regular transclude here because it breaks element.data()
              //inheritance on compile
              var innerElement = jqLite('<div class="tab-nav tabs">');
              innerElement.append(tElement.contents());
        Severity: Minor
        Found in examples/ionic/www/lib/ionic/js/ionic-angular.js - About 1 hr to fix

          Consider simplifying this complex logical expression.
          Open

                  if (isSwipingRight && (releaseSwipeCompletion > 0.5 || velocity > 0.1)) {
                    // complete view transition on release
                    var speed = (velocity > 0.5 || velocity < 0.05 || releaseX > windowWidth - 45) ? 'fast' : 'slow';
                    navSwipeAttr(disableAnimation ? '' : speed);
                    backView.go();
          Severity: Critical
          Found in examples/ionic/www/lib/ionic/js/ionic-angular.js - About 1 hr to fix

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

                        if (accessToken) {
                            if (angular.isObject(accessToken) && angular.isObject(accessToken.data)) {
                                response = accessToken;
                            }
                            else if (angular.isString(accessToken)) {
            Severity: Major
            Found in examples/ionic/www/lib/satellizer/dist/satellizer.js and 1 other location - About 1 hr to fix
            examples/ionic/www/lib/satellizer/satellizer.js on lines 329..335

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

            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

                      if (accessToken) {
                        if (angular.isObject(accessToken) && angular.isObject(accessToken.data)) {
                          response = accessToken;
                        } else if (angular.isString(accessToken)) {
                          token = accessToken;
            Severity: Major
            Found in examples/ionic/www/lib/satellizer/satellizer.js and 1 other location - About 1 hr to fix
            examples/ionic/www/lib/satellizer/dist/satellizer.js on lines 427..434

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

            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

              self.showBar = function(val) {
                var associatedNavBarCtrl = getAssociatedNavBarCtrl();
                if (associatedNavBarCtrl) {
                  if (arguments.length) {
                    return associatedNavBarCtrl.showBar(val);
            Severity: Major
            Found in examples/ionic/www/lib/ionic/js/ionic-angular.js and 1 other location - About 1 hr to fix
            examples/ionic/www/lib/ionic/js/ionic-angular.js on lines 6379..6388

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

            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

              self.showBackButton = function(shouldShow) {
                var associatedNavBarCtrl = getAssociatedNavBarCtrl();
                if (associatedNavBarCtrl) {
                  if (arguments.length) {
                    return associatedNavBarCtrl.showActiveBackButton(shouldShow);
            Severity: Major
            Found in examples/ionic/www/lib/ionic/js/ionic-angular.js and 1 other location - About 1 hr to fix
            examples/ionic/www/lib/ionic/js/ionic-angular.js on lines 6391..6400

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

            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

            Function compile has 41 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                compile: function($element, $attrs) {
                  var isAnchor = isDefined($attrs.href) ||
                                 isDefined($attrs.ngHref) ||
                                 isDefined($attrs.uiSref);
                  var isComplexItem = isAnchor ||
            Severity: Minor
            Found in examples/ionic/www/lib/ionic/js/ionic-angular.js - About 1 hr to fix

              Function parseDimensionAttr has 41 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  function parseDimensionAttr(attrValue, dimensionData) {
                    if (!attrValue) return;
              
                    var parsedValue;
                    // Try to just parse the plain attr value
              Severity: Minor
              Found in examples/ionic/www/lib/ionic/js/ionic-angular.js - About 1 hr to fix

                Function updateRenderRange has 41 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                      this.updateRenderRange = function(scrollValue, scrollValueEnd) {
                        var i;
                        var len;
                        var dim;
                
                
                Severity: Minor
                Found in examples/ionic/www/lib/ionic/js/ionic-angular.js - About 1 hr to fix

                  Function compile has 40 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                        compile: function(tElement) {
                          tElement.addClass(isHeader ? 'bar bar-header' : 'bar bar-footer');
                          // top style tabs? if so, remove bottom border for seamless display
                          $timeout(function() {
                            if (isHeader && $document[0].getElementsByClassName('tabs-top').length) tElement.addClass('has-tabs-top');
                  Severity: Minor
                  Found in examples/ionic/www/lib/ionic/js/ionic-angular.js - About 1 hr to fix

                    Function handleTouchmove has 40 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                        function handleTouchmove(e) {
                          // if multitouch or regular scroll event, get out immediately
                          if (!canOverscroll || e.touches.length > 1) {
                            return;
                          }
                    Severity: Minor
                    Found in examples/ionic/www/lib/ionic/js/ionic-angular.js - About 1 hr to fix

                      Function show has 40 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                              self.show = function(options) {
                                var templatePromise = options.templateUrl ?
                                  $ionicTemplateLoader.load(options.templateUrl) :
                                  //options.content: deprecated
                                  $q.when(options.template || options.content || '');
                      Severity: Minor
                      Found in examples/ionic/www/lib/ionic/js/ionic-angular.js - About 1 hr to fix

                        Method instagram has 40 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                            public function instagram(Request $request)
                            {
                                $client = new GuzzleHttp\Client();
                        
                                $params = [
                        Severity: Minor
                        Found in examples/server/php/app/Http/Controllers/AuthController.php - About 1 hr to fix
                          Severity
                          Category
                          Status
                          Source
                          Language