CaffGeek/MBACNationals

View on GitHub

Showing 5,566 of 7,504 total issues

Function get_terms has a Cognitive Complexity of 119 (exceeds 5 allowed). Consider refactoring.
Open

function &get_terms($taxonomies, $args = '') {
    global $wpdb;
    $empty_array = array();

    $single_taxonomy = false;
Severity: Minor
Found in Web.Admin/2014/wordpress/wp-includes/taxonomy.php - About 2 days to fix

Cognitive Complexity

Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

A method's cognitive complexity is based on a few simple rules:

  • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
  • Code is considered more complex for each "break in the linear flow of the code"
  • Code is considered more complex when "flow breaking structures are nested"

Further reading

File http.php has 963 lines of code (exceeds 250 allowed). Consider refactoring.
Open

<?php
/**
 * Simple and uniform HTTP request API.
 *
 * Will eventually replace and standardize the WordPress HTTP requests made.
Severity: Major
Found in Web.Admin/2014/wordpress/wp-includes/http.php - About 2 days to fix

    File akismet.php has 941 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    <?php
    /*
    Plugin Name: Akismet
    Plugin URI: http://akismet.com/
    Description: Akismet checks your comments against the Akismet web service to see if they look like spam or not. You need a <a href="http://akismet.com/get/">WordPress.com API key</a> to use it. You can review the spam it catches under "Comments." To show off your Akismet stats just put <code>&lt;?php akismet_counter(); ?&gt;</code> in your template. See also: <a href="http://wordpress.org/extend/plugins/stats/">WP Stats plugin</a>.
    Severity: Major
    Found in Web.Admin/2014/wordpress/wp-content/plugins/akismet/akismet.php - About 2 days to fix

      Function get_themes has a Cognitive Complexity of 115 (exceeds 5 allowed). Consider refactoring.
      Open

      function get_themes() {
          global $wp_themes, $wp_broken_themes;
      
          if ( isset($wp_themes) )
              return $wp_themes;
      Severity: Minor
      Found in Web.Admin/2014/wordpress/wp-includes/theme.php - About 2 days to fix

      Cognitive Complexity

      Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

      A method's cognitive complexity is based on a few simple rules:

      • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
      • Code is considered more complex for each "break in the linear flow of the code"
      • Code is considered more complex when "flow breaking structures are nested"

      Further reading

      File angular-mocks.js has 940 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 Web.Admin/z-scripts/angular-mocks.js - About 2 days to fix

        File pluggable.php has 933 lines of code (exceeds 250 allowed). Consider refactoring.
        Open

        <?php
        /**
         * These functions can be replaced via plugins. If plugins do not redefine these
         * functions, then these will be used instead.
         *
        Severity: Major
        Found in Web.Admin/2014/wordpress/wp-includes/pluggable.php - About 2 days to fix

          File link-template.php has 933 lines of code (exceeds 250 allowed). Consider refactoring.
          Open

          <?php
          /**
           * WordPress Link Template Functions
           *
           * @package WordPress
          Severity: Major
          Found in Web.Admin/2014/wordpress/wp-includes/link-template.php - About 2 days to fix

            File media-template.php has 928 lines of code (exceeds 250 allowed). Consider refactoring.
            Open

            <?php
            /**
             * WordPress media templates.
             *
             * @package WordPress
            Severity: Major
            Found in Web.Admin/2014/wordpress/wp-includes/media-template.php - About 2 days to fix

              File class-http.php has 928 lines of code (exceeds 250 allowed). Consider refactoring.
              Open

              <?php
              /**
               * Simple and uniform HTTP request API.
               *
               * Standardizes the HTTP requests for WordPress. Handles cookies, gzip encoding and decoding, chunk
              Severity: Major
              Found in Web.Admin/2014/wordpress/wp-includes/class-http.php - About 2 days to fix

                File nav-menu.php has 924 lines of code (exceeds 250 allowed). Consider refactoring.
                Open

                <?php
                
                /**
                 * Create HTML list of nav menu input items.
                 *
                Severity: Major
                Found in Web.Admin/2014/wordpress/wp-admin/includes/nav-menu.php - About 2 days to fix

                  File comment.php has 916 lines of code (exceeds 250 allowed). Consider refactoring.
                  Open

                  <?php
                  /**
                   * Manages WordPress comments
                   *
                   * @package WordPress
                  Severity: Major
                  Found in Web.Admin/2014/wordpress/wp-includes/comment.php - About 2 days to fix

                    File post.php has 911 lines of code (exceeds 250 allowed). Consider refactoring.
                    Open

                    <?php
                    /**
                     * WordPress Post Administration API.
                     *
                     * @package WordPress
                    Severity: Major
                    Found in Web.Admin/2014/wordpress/wp-admin/includes/post.php - About 2 days to fix

                      Function tb_show has a Cognitive Complexity of 110 (exceeds 5 allowed). Consider refactoring.
                      Open

                      function tb_show(caption, url, imageGroup) {//function called when the user clicks on a thickbox link
                      
                          try {
                              if (typeof document.body.style.maxHeight === "undefined") {//if IE 6
                                  jQuery("body","html").css({height: "100%", width: "100%"});
                      Severity: Minor
                      Found in Web.Admin/2014/wordpress/wp-includes/js/thickbox/thickbox.js - About 2 days to fix

                      Cognitive Complexity

                      Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                      A method's cognitive complexity is based on a few simple rules:

                      • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                      • Code is considered more complex for each "break in the linear flow of the code"
                      • Code is considered more complex when "flow breaking structures are nested"

                      Further reading

                      Function HandleAllTags has a Cognitive Complexity of 110 (exceeds 5 allowed). Consider refactoring.
                      Open

                          public function HandleAllTags() {
                      
                              // key name => array (tag name, character encoding)
                              static $tags;
                              if (empty($tags)) {
                      Severity: Minor
                      Found in Web.Admin/2014/wordpress/wp-includes/ID3/getid3.php - About 2 days to fix

                      Cognitive Complexity

                      Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                      A method's cognitive complexity is based on a few simple rules:

                      • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                      • Code is considered more complex for each "break in the linear flow of the code"
                      • Code is considered more complex when "flow breaking structures are nested"

                      Further reading

                      Function $StateProvider has 440 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                      function $StateProvider(   $urlRouterProvider,   $urlMatcherFactory) {
                      
                        var root, states = {}, $state, queue = {}, abstractKey = 'abstract';
                      
                        // Builds state properties from definition passed to registerState()
                      Severity: Major
                      Found in Web.Admin/z-scripts/angular-ui-router.js - About 2 days to fix

                        File class-wp-editor.php has 899 lines of code (exceeds 250 allowed). Consider refactoring.
                        Open

                        <?php
                        /**
                         * Facilitates adding of the WordPress editor as used on the Write and Edit screens.
                         *
                         * @package WordPress
                        Severity: Major
                        Found in Web.Admin/2014/wordpress/wp-includes/class-wp-editor.php - About 2 days to fix

                          Method entity has 438 lines of code (exceeds 25 allowed). Consider refactoring.
                          Open

                              public function entity()
                              {
                                  switch ($this->consume())
                                  {
                                      case "\x09":

                            File nav-menu.js has 895 lines of code (exceeds 250 allowed). Consider refactoring.
                            Open

                            /**
                             * WordPress Administration Navigation Menu
                             * Interface JS functions
                             *
                             * @version 2.0.0
                            Severity: Major
                            Found in Web.Admin/2014/wordpress/wp-admin/js/nav-menu.js - About 2 days to fix

                              Function featuredslider has 434 lines of code (exceeds 25 allowed). Consider refactoring.
                              Open

                                  $.featuredslider = function( el, options ) {
                                      var slider = $( el ),
                                          msGesture = window.navigator && window.navigator.msPointerEnabled && window.MSGesture,
                                          touch = ( ( 'ontouchstart' in window ) || msGesture || window.DocumentTouch && document instanceof DocumentTouch ), // MSFT specific.
                                          eventType = 'click touchend MSPointerUp',
                              Severity: Major
                              Found in Web.Admin/2014/wordpress/wp-content/themes/twentyfourteen/js/slider.js - About 2 days to fix

                                File ng-file-upload-all.js has 888 lines of code (exceeds 250 allowed). Consider refactoring.
                                Open

                                /**!
                                 * AngularJS file upload/drop directive and service with progress and abort
                                 * @author  Danial  <danial.farid@gmail.com>
                                 * @version 4.2.1
                                 */
                                Severity: Major
                                Found in Web.Admin/z-scripts/ng-file-upload-all.js - About 2 days to fix
                                  Severity
                                  Category
                                  Status
                                  Source
                                  Language