JohnMunsch/PaperQuik

View on GitHub
app/bower_components/angular-route/angular-route.js

Summary

Maintainability
F
3 days
Test Coverage

Function $RouteProvider has 185 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function $RouteProvider(){
  function inherit(parent, extra) {
    return angular.extend(new (angular.extend(function() {}, {prototype:parent}))(), extra);
  }

Severity: Major
Found in app/bower_components/angular-route/angular-route.js - About 7 hrs to fix

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

          function($rootScope, $location, $routeParams, $q, $injector, $http, $templateCache, $sce) {
    
        /**
         * @ngdoc service
         * @name $route
    Severity: Major
    Found in app/bower_components/angular-route/angular-route.js - About 4 hrs to fix

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

          function updateRoute() {
            var next = parseRoute(),
                last = $route.current;
      
            if (next && last && next.$$route === last.$$route
      Severity: Major
      Found in app/bower_components/angular-route/angular-route.js - About 2 hrs to fix

        File angular-route.js has 278 lines of code (exceeds 250 allowed). Consider refactoring.
        Open

        /**
         * @license AngularJS v1.2.20
         * (c) 2010-2014 Google, Inc. http://angularjs.org
         * License: MIT
         */
        Severity: Minor
        Found in app/bower_components/angular-route/angular-route.js - About 2 hrs to fix

          Function ngViewFactory has 55 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

          function ngViewFactory(   $route,   $anchorScroll,   $animate) {
            return {
              restrict: 'ECA',
              terminal: true,
              priority: 400,
          Severity: Major
          Found in app/bower_components/angular-route/angular-route.js - About 2 hrs to fix

            Function link has 47 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                link: function(scope, $element, attr, ctrl, $transclude) {
                    var currentScope,
                        currentElement,
                        previousElement,
                        autoScrollExp = attr.autoscroll,
            Severity: Minor
            Found in app/bower_components/angular-route/angular-route.js - About 1 hr to fix

              Function $get has 8 arguments (exceeds 4 allowed). Consider refactoring.
              Open

                    function($rootScope, $location, $routeParams, $q, $injector, $http, $templateCache, $sce) {
              Severity: Major
              Found in app/bower_components/angular-route/angular-route.js - About 1 hr to fix

                Avoid deeply nested control flow statements.
                Open

                                if (angular.isDefined(templateUrl)) {
                                  next.loadedTemplateUrl = templateUrl;
                                  template = $http.get(templateUrl, {cache: $templateCache}).
                                      then(function(response) { return response.data; });
                                }
                Severity: Major
                Found in app/bower_components/angular-route/angular-route.js - About 45 mins to fix

                  Avoid deeply nested control flow statements.
                  Open

                                  if (angular.isFunction(templateUrl)) {
                                    templateUrl = templateUrl(next.params);
                                  }
                  Severity: Major
                  Found in app/bower_components/angular-route/angular-route.js - About 45 mins to fix

                    Consider simplifying this complex logical expression.
                    Open

                          if (next && last && next.$$route === last.$$route
                              && angular.equals(next.pathParams, last.pathParams)
                              && !next.reloadOnSearch && !forceReload) {
                            last.params = next.params;
                            angular.copy(last.params, $routeParams);
                    Severity: Major
                    Found in app/bower_components/angular-route/angular-route.js - About 40 mins to fix

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

                          link: function(scope, $element, attr, ctrl, $transclude) {
                      Severity: Minor
                      Found in app/bower_components/angular-route/angular-route.js - About 35 mins to fix

                        There are no issues that match your filters.

                        Category
                        Status