CaffGeek/MBACNationals

View on GitHub

Showing 7,504 of 7,504 total issues

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

function delete_site_transient( $transient ) {

    /**
     * Fires immediately before a specific site transient is deleted.
     *
Severity: Major
Found in Web.Admin/2014/wordpress/wp-includes/option.php and 1 other location - About 2 hrs to fix
Web.Admin/2014/wordpress/wp-includes/option.php on lines 513..549

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

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

    window.FileReader = function() {
        var _this = this, loadStarted = false;
        this.listeners = {};
        this.addEventListener = function(type, fn) {
            _this.listeners[type] = _this.listeners[type] || [];
Severity: Major
Found in Web.Admin/z-scripts/ng-file-upload-all.js - About 2 hrs to fix

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

        window.FileReader = function() {
            var _this = this, loadStarted = false;
            this.listeners = {};
            this.addEventListener = function(type, fn) {
                _this.listeners[type] = _this.listeners[type] || [];
    Severity: Major
    Found in Web.Admin/z-scripts/ng-file-upload-shim.js - About 2 hrs to fix

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

                  link: function (scope, element, attrs) {
                      scope.$watch('shots', function () {
                          scope.shots = scope.shots.toUpperCase();
                          scope.game = { frames: [], score: 0, fouls: 0 };
      
      
      Severity: Major
      Found in Web.Admin/AdminApp/Controllers/controller.stepladder.js - About 2 hrs to fix

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

            add: function(handleObj) {
        
                var getCoords = function(e) {
                    if ( e.touches && e.touches.length ) {
                        var touch = e.touches[0];
        Severity: Major
        Found in Web.Admin/2015/js/galleria/galleria-1.4.2.js - About 2 hrs to fix

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

                      link: function (scope, element, attrs) {
                          scope.$watch('shots', function () {
                              scope.shots = (scope.shots || '').toUpperCase();
                              scope.game = { frames: [], score: 0, fouls: 0 };
          
          
          Severity: Major
          Found in Web.Admin/ClientApp/Controllers/controller.results.js - About 2 hrs to fix

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

                ajaxDim: function( e, s ) {
                    if ( $(e).parent().css('display') == 'none' ) // Prevent hidden links from being clicked by hotkeys
                        return false;
                    e = $(e); s = s || {};
                    var list = this, cls = wpList.parseClass(e,'dim'), element, isClass, color, dimColor;
            Severity: Major
            Found in Web.Admin/2014/wordpress/wp-includes/js/wp-lists.dev.js - About 2 hrs to fix

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

              tinymce.WPWindowManager = tinymce.InlineWindowManager = function( editor ) {
                  if ( this.wp ) {
                      return this;
                  }
              
              

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

                    add: function(handleObj) {
                
                        var getCoords = function(e) {
                            if ( e.touches && e.touches.length ) {
                                var touch = e.touches[0];
                Severity: Major
                Found in Web.Admin/Content/galleria/galleria-1.4.2.js - About 2 hrs to fix

                  Method js_1 has 55 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                      function js_1() { ?>
                  <script type="text/javascript">
                      var buttons = ['#name', '#desc', '#pickcolor', '#defaultcolor'];
                      var farbtastic;
                  
                  
                  Severity: Major
                  Found in Web.Admin/2014/wordpress/wp-admin/custom-header.php - About 2 hrs to fix

                    Method login_header has 55 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                    function login_header($title = 'Log In', $message = '', $wp_error = '') {
                        global $error, $is_iphone, $interim_login;
                    
                        // Don't index any of these forms
                        add_filter( 'pre_option_blog_public', create_function( '$a', 'return 0;' ) );
                    Severity: Major
                    Found in Web.Admin/2014/wordpress/wp-login.php - About 2 hrs to fix

                      Method twentythirteen_admin_header_style has 55 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                      function twentythirteen_admin_header_style() {
                          $header_image = get_header_image();
                      ?>
                          <style type="text/css" id="twentythirteen-admin-header-css">
                          .appearance_page_custom-header #headimg {

                        Method wp_get_nav_menu_items has 55 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                        function wp_get_nav_menu_items( $menu, $args = array() ) {
                            $menu = wp_get_nav_menu_object( $menu );
                        
                            if ( ! $menu )
                                return false;
                        Severity: Major
                        Found in Web.Admin/2014/wordpress/wp-includes/nav-menu.php - About 2 hrs to fix

                          Method wp_underscore_video_template has 55 lines of code (exceeds 25 allowed). Consider refactoring.
                          Open

                          function wp_underscore_video_template() {
                              $video_types = wp_get_video_extensions();
                          ?>
                          <#  var w, h, settings = wp.media.view.settings,
                                  isYouTube = ! _.isEmpty( data.model.src ) && data.model.src.match(/youtube|youtu\.be/);
                          Severity: Major
                          Found in Web.Admin/2014/wordpress/wp-includes/media-template.php - About 2 hrs to fix

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

                                render: function() {
                            
                                    // Render results
                                    this.view.render();
                                    this.routes();
                            Severity: Major
                            Found in Web.Admin/2014/wordpress/wp-admin/js/theme.js and 1 other location - About 2 hrs to fix
                            Web.Admin/2014/wordpress/wp-admin/js/theme.js on lines 1203..1214

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

                            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

                            dw_Rotator.setup = function () {
                                var rObj, r;
                                for (var i=0; arguments[i]; i++) {
                                    rObj = arguments[i];
                                    r = new dw_Rotator(rObj);
                            Severity: Major
                            Found in Web.Admin/2014/js/dw_rotator.js and 1 other location - About 2 hrs to fix
                            Web.Admin/2015/js/dw_rotator.js on lines 177..184

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

                            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

                                    toView:  function( content ) {
                                        var match = wp.shortcode.next( this.shortcode, content );
                            
                                        if ( ! match ) {
                                            return;
                            Severity: Major
                            Found in Web.Admin/2014/wordpress/wp-includes/js/mce-view.js and 1 other location - About 2 hrs to fix
                            Web.Admin/2014/wordpress/wp-includes/js/mce-view.js on lines 363..377

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

                            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

                            dw_Rotator.setup = function () {
                                var rObj, r;
                                for (var i=0; arguments[i]; i++) {
                                    rObj = arguments[i];
                                    r = new dw_Rotator(rObj);
                            Severity: Major
                            Found in Web.Admin/2015/js/dw_rotator.js and 1 other location - About 2 hrs to fix
                            Web.Admin/2014/js/dw_rotator.js on lines 177..184

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

                            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

                                    toView:  function( content ) {
                                        var match = wp.shortcode.next( this.shortcode, content );
                            
                                        if ( ! match ) {
                                            return;
                            Severity: Major
                            Found in Web.Admin/2014/wordpress/wp-includes/js/mce-view.js and 1 other location - About 2 hrs to fix
                            Web.Admin/2014/wordpress/wp-includes/js/mce-view.js on lines 257..271

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

                            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

                                render: function() {
                            
                                    // Render results
                                    this.view.render();
                                    this.routes();
                            Severity: Major
                            Found in Web.Admin/2014/wordpress/wp-admin/js/theme.js and 1 other location - About 2 hrs to fix
                            Web.Admin/2014/wordpress/wp-admin/js/theme.js on lines 1606..1617

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

                            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