preston/bittorious

View on GitHub

Showing 235 of 235 total issues

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

 */(function() {

var restangular = angular.module('restangular', []);

restangular.provider('Restangular', function() {
Severity: Major
Found in lib/assets/bower_components/restangular/dist/restangular.js and 1 other location - About 2 mos to fix
lib/assets/bower_components/restangular/src/restangular.js on lines 1..1350

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

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

(function() {

var restangular = angular.module('restangular', []);

restangular.provider('Restangular', function() {
Severity: Major
Found in lib/assets/bower_components/restangular/src/restangular.js and 1 other location - About 2 mos to fix
lib/assets/bower_components/restangular/dist/restangular.js on lines 6..1355

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

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 runInContext has 3983 lines of code (exceeds 25 allowed). Consider refactoring.
Open

  function runInContext(context) {
    // Avoid issues with some ES3 environments that attempt to use values, named
    // after built-in constructors like `Object`, for the creation of literals.
    // ES5 clears this up by stating that literals must use built-in constructors.
    // See https://es5.github.io/#x11.1.5 for more details.
Severity: Major
Found in lib/assets/bower_components/lodash/lodash.js - About 2 wks to fix

    File lodash.js has 4333 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    /**
     * @license
     * lodash 3.10.0 (Custom Build) <https://lodash.com/>
     * Build: `lodash modern -o ./lodash.js`
     * Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/>
    Severity: Major
    Found in lib/assets/bower_components/lodash/lodash.js - About 1 wk to fix

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

      /**
       * @license AngularJS v1.4.3
       * (c) 2010-2015 Google, Inc. http://angularjs.org
       * License: MIT
       */
      Severity: Major
      Found in lib/assets/bower_components/angular-animate/angular-animate.js - About 5 days to fix

        Function $translate has 917 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

        function $translate($STORAGE_KEY, $windowProvider, $translateSanitizationProvider, pascalprechtTranslateOverrider) {
        
          'use strict';
        
          var $translationTable = {},
        Severity: Major
        Found in lib/assets/bower_components/angular-translate/angular-translate.js - About 4 days to fix

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

          /*!
           * angular-translate - v2.7.2 - 2015-06-01
           * http://github.com/angular-translate/angular-translate
           * Copyright (c) 2015 ; Licensed MIT
           */
          Severity: Major
          Found in lib/assets/bower_components/angular-translate/angular-translate.js - About 3 days to fix

            Function init has 549 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

              Configurer.init = function(object, config) {
                object.configuration = config;
            
                /**
                 * Those are HTTP safe methods for which there is no need to pass any data with the request.
            Severity: Major
            Found in lib/assets/bower_components/restangular/dist/restangular.js - About 2 days to fix

              Function init has 549 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                Configurer.init = function(object, config) {
                  object.configuration = config;
              
                  /**
                   * Those are HTTP safe methods for which there is no need to pass any data with the request.
              Severity: Major
              Found in lib/assets/bower_components/restangular/src/restangular.js - About 2 days to fix

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

                    function ($log, $injector, $rootScope, $q) {
                
                      var Storage,
                          defaultInterpolator = $injector.get($interpolationFactory || '$translateDefaultInterpolation'),
                          pendingLoader = false,
                Severity: Major
                Found in lib/assets/bower_components/angular-translate/angular-translate.js - About 2 days to fix

                  File restangular.js has 1044 lines of code (exceeds 250 allowed). Consider refactoring.
                  Open

                  (function() {
                  
                  var restangular = angular.module('restangular', []);
                  
                  restangular.provider('Restangular', function() {
                  Severity: Major
                  Found in lib/assets/bower_components/restangular/src/restangular.js - About 2 days to fix

                    File restangular.js has 1043 lines of code (exceeds 250 allowed). Consider refactoring.
                    Open

                    /**
                     * Restful Resources service for AngularJS apps
                     * @version v1.4.0 - 2015-04-03 * @link https://github.com/mgonto/restangular
                     * @author Martin Gontovnikas <martin@gon.to>
                     * @license MIT License, http://www.opensource.org/licenses/MIT
                    Severity: Major
                    Found in lib/assets/bower_components/restangular/dist/restangular.js - About 2 days to fix

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

                        this.$get = ['$http', '$q', function($http, $q) {
                      
                          function createServiceForConfiguration(config) {
                            var service = {};
                      
                      
                      Severity: Major
                      Found in lib/assets/bower_components/restangular/src/restangular.js - About 2 days to fix

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

                          this.$get = ['$http', '$q', function($http, $q) {
                        
                            function createServiceForConfiguration(config) {
                              var service = {};
                        
                        
                        Severity: Major
                        Found in lib/assets/bower_components/restangular/dist/restangular.js - About 2 days to fix

                          Function createServiceForConfiguration has 480 lines of code (exceeds 25 allowed). Consider refactoring.
                          Open

                              function createServiceForConfiguration(config) {
                                var service = {};
                          
                                var urlHandler = new config.urlCreatorFactory[config.urlCreator]();
                                urlHandler.setConfig(config);
                          Severity: Major
                          Found in lib/assets/bower_components/restangular/src/restangular.js - About 2 days to fix

                            Function createServiceForConfiguration has 480 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                                function createServiceForConfiguration(config) {
                                  var service = {};
                            
                                  var urlHandler = new config.urlCreatorFactory[config.urlCreator]();
                                  urlHandler.setConfig(config);
                            Severity: Major
                            Found in lib/assets/bower_components/restangular/dist/restangular.js - About 2 days to fix

                              Function $$AnimateQueueProvider has 411 lines of code (exceeds 25 allowed). Consider refactoring.
                              Open

                              var $$AnimateQueueProvider = ['$animateProvider', function($animateProvider) {
                                var PRE_DIGEST_STATE = 1;
                                var RUNNING_STATE = 2;
                              
                                var rules = this.rules = {
                              Severity: Major
                              Found in lib/assets/bower_components/angular-animate/angular-animate.js - About 2 days to fix

                                Function $AnimateCssProvider has 398 lines of code (exceeds 25 allowed). Consider refactoring.
                                Open

                                var $AnimateCssProvider = ['$animateProvider', function($animateProvider) {
                                  var gcsLookup = createLocalCacheLookup();
                                  var gcsStaggerLookup = createLocalCacheLookup();
                                
                                  this.$get = ['$window', '$$jqLite', '$$AnimateRunner', '$timeout',
                                Severity: Major
                                Found in lib/assets/bower_components/angular-animate/angular-animate.js - About 1 day to fix

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

                                         function($window,   $$jqLite,   $$AnimateRunner,   $timeout,
                                                  $document,   $sniffer,   $$rAFScheduler) {
                                  
                                      var applyAnimationClasses = applyAnimationClassesFactory($$jqLite);
                                  
                                  
                                  Severity: Major
                                  Found in lib/assets/bower_components/angular-animate/angular-animate.js - About 1 day to fix

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

                                           function($$rAF,   $rootScope,   $rootElement,   $document,   $$HashMap,
                                                    $$animation,   $$AnimateRunner,   $templateRequest,   $$jqLite) {
                                    
                                        var activeAnimationsLookup = new $$HashMap();
                                        var disabledElementsLookup = new $$HashMap();
                                    Severity: Major
                                    Found in lib/assets/bower_components/angular-animate/angular-animate.js - About 1 day to fix
                                      Severity
                                      Category
                                      Status
                                      Source
                                      Language