CaffGeek/MBACNationals

View on GitHub

Showing 5,566 of 7,504 total issues

Method editor_js has 125 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    public static function editor_js() {
        global $tinymce_version, $concatenate_scripts, $compress_scripts;

        /**
         * Filter "tiny_mce_version" is deprecated
Severity: Major
Found in Web.Admin/2014/wordpress/wp-includes/class-wp-editor.php - About 5 hrs to fix

    File handlers.js has 374 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    /* global plupload, pluploadL10n, ajaxurl, post_id, wpUploaderInit, deleteUserSetting, setUserSetting, getUserSetting, shortform */
    var topWin = window.dialogArguments || opener || parent || top, uploader, uploader_init;
    
    // progress and success handlers for media multi uploads
    function fileQueued(fileObj) {
    Severity: Minor
    Found in Web.Admin/2014/wordpress/wp-includes/js/plupload/handlers.js - About 5 hrs to fix

      Function $Resolve has 124 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

      function $Resolve(  $q,    $injector) {
        
        var VISIT_IN_PROGRESS = 1,
            VISIT_DONE = 2,
            NOTHING = {},
      Severity: Major
      Found in Web.Admin/z-scripts/angular-ui-router.js - About 4 hrs to fix

        Function touch has 124 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

                    touch: function() {
                        var startX,
                            startY,
                            offset,
                            cwidth,

          File heartbeat.js has 372 lines of code (exceeds 250 allowed). Consider refactoring.
          Open

          /**
           * Heartbeat API
           *
           * Heartbeat is a simple server polling API that sends XHR requests to
           * the server every 15 - 60 seconds and triggers events (or callbacks) upon
          Severity: Minor
          Found in Web.Admin/2014/wordpress/wp-includes/js/heartbeat.js - About 4 hrs to fix

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

                    updateWidget: function( args ) {
                        var self = this, instanceOverride, completeCallback, $widgetRoot, $widgetContent,
                            updateNumber, params, data, $inputs, processing, jqxhr, isChanged;
            
                        args = $.extend( {
            Severity: Major
            Found in Web.Admin/2014/wordpress/wp-admin/js/customize-widgets.js - About 4 hrs to fix

              Method parse_request has 123 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  function parse_request($extra_query_vars = '') {
                      global $wp_rewrite;
              
                      /**
                       * Filter whether to parse the request.
              Severity: Major
              Found in Web.Admin/2014/wordpress/wp-includes/class-wp.php - About 4 hrs to fix

                Function addMethods has a Cognitive Complexity of 33 (exceeds 5 allowed). Consider refactoring.
                Open

                Element.addMethods = function(methods) {
                  var F = Prototype.BrowserFeatures, T = Element.Methods.ByTag;
                
                  if (!methods) {
                    Object.extend(Form, Form.Methods);
                Severity: Minor
                Found in Web.Admin/2014/wordpress/wp-includes/js/prototype.js - About 4 hrs 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 addMethods has a Cognitive Complexity of 33 (exceeds 5 allowed). Consider refactoring.
                Open

                Element.addMethods = function(methods) {
                  var F = Prototype.BrowserFeatures, T = Element.Methods.ByTag;
                
                  if (!methods) {
                    Object.extend(Form, Form.Methods);
                Severity: Minor
                Found in Web.Admin/2014/wordpress/wp-includes/js/scriptaculous/prototype.js - About 4 hrs 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 screen_meta has a Cognitive Complexity of 33 (exceeds 5 allowed). Consider refactoring.
                Open

                function screen_meta($screen) {
                    global $wp_meta_boxes, $_wp_contextual_help;
                
                    $screen = str_replace('.php', '', $screen);
                    $screen = str_replace('-new', '', $screen);
                Severity: Minor
                Found in Web.Admin/2014/wordpress/wp-admin/includes/template.php - About 4 hrs 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 prepare_items has a Cognitive Complexity of 33 (exceeds 5 allowed). Consider refactoring.
                Open

                    function prepare_items() {
                        global $s, $mode, $wpdb;
                
                        $current_site = get_current_site();
                
                

                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 media_upload_library_form has a Cognitive Complexity of 33 (exceeds 5 allowed). Consider refactoring.
                Open

                function media_upload_library_form($errors) {
                    global $wpdb, $wp_query, $wp_locale, $type, $tab, $post_mime_types;
                
                    media_upload_header();
                
                
                Severity: Minor
                Found in Web.Admin/2014/wordpress/wp-admin/includes/media.php - About 4 hrs 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 install_package has a Cognitive Complexity of 33 (exceeds 5 allowed). Consider refactoring.
                Open

                    function install_package($args = array()) {
                        global $wp_filesystem;
                        $defaults = array( 'source' => '', 'destination' => '', //Please always pass these
                                        'clear_destination' => false, 'clear_working' => false,
                                        'hook_extra' => array());
                Severity: Minor
                Found in Web.Admin/2014/wordpress/wp-admin/includes/class-wp-upgrader.php - About 4 hrs 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 wp_insert_link has a Cognitive Complexity of 33 (exceeds 5 allowed). Consider refactoring.
                Open

                function wp_insert_link( $linkdata, $wp_error = false ) {
                    global $wpdb, $current_user;
                
                    $defaults = array( 'link_id' => 0, 'link_name' => '', 'link_url' => '', 'link_rating' => 0 );
                
                
                Severity: Minor
                Found in Web.Admin/2014/wordpress/wp-admin/includes/bookmark.php - About 4 hrs 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 import_posts has a Cognitive Complexity of 33 (exceeds 5 allowed). Consider refactoring.
                Open

                    function import_posts() {
                        global $wpdb, $current_user;
                
                        set_magic_quotes_runtime(0);
                        $importdata = file($this->file); // Read the file into an array
                Severity: Minor
                Found in Web.Admin/2014/wordpress/wp-admin/import/blogware.php - About 4 hrs 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 pingback_ping has a Cognitive Complexity of 33 (exceeds 5 allowed). Consider refactoring.
                Open

                    function pingback_ping($args) {
                        global $wpdb;
                
                        /** This action is documented in wp-includes/class-wp-xmlrpc-server.php */
                        do_action( 'xmlrpc_call', 'pingback.ping' );
                Severity: Minor
                Found in Web.Admin/2014/wordpress/wp-includes/class-wp-xmlrpc-server.php - About 4 hrs 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 readData has a Cognitive Complexity of 33 (exceeds 5 allowed). Consider refactoring.
                Open

                    public function readData() {
                        $this->skipBits(8);
                        $this->skipBits(8);
                        $profile = $this->getBits(8);    //    read profile
                        $this->skipBits(16);
                Severity: Minor
                Found in Web.Admin/2014/wordpress/wp-includes/ID3/module.audio-video.flv.php - About 4 hrs 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 getHashdata has a Cognitive Complexity of 33 (exceeds 5 allowed). Consider refactoring.
                Open

                    public function getHashdata($algorithm) {
                        switch ($algorithm) {
                            case 'md5':
                            case 'sha1':
                                break;
                Severity: Minor
                Found in Web.Admin/2014/wordpress/wp-includes/ID3/getid3.php - About 4 hrs 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 _getTransport has a Cognitive Complexity of 33 (exceeds 5 allowed). Consider refactoring.
                Open

                    function &_getTransport( $args = array() ) {
                        static $working_transport, $blocking_transport, $nonblocking_transport;
                
                        if ( is_null($working_transport) ) {
                            if ( true === WP_Http_ExtHttp::test($args) ) {
                Severity: Minor
                Found in Web.Admin/2014/wordpress/wp-includes/http.php - About 4 hrs 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 wp_save_post_revision has a Cognitive Complexity of 33 (exceeds 5 allowed). Consider refactoring.
                Open

                function wp_save_post_revision( $post_id ) {
                    if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE )
                        return;
                
                    if ( ! $post = get_post( $post_id ) )
                Severity: Minor
                Found in Web.Admin/2014/wordpress/wp-includes/revision.php - About 4 hrs 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

                Severity
                Category
                Status
                Source
                Language