CaffGeek/MBACNationals

View on GitHub

Showing 5,566 of 7,504 total issues

Function Shrink has 48 lines of code (exceeds 25 allowed). Consider refactoring.
Open

Effect.Shrink = function(element) {
  element = $(element);
  var options = Object.extend({
    direction: 'center',
    moveTransition: Effect.Transitions.sinoidal,
Severity: Minor
Found in Web.Admin/2014/wordpress/wp-includes/js/scriptaculous/effects.js - About 1 hr to fix

    Function bindHandlers has 48 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

            bindHandlers: function() {
                var handlers, checkCounts;
    
                media.view.MediaFrame.Select.prototype.bindHandlers.apply( this, arguments );
    
    
    Severity: Minor
    Found in Web.Admin/2014/wordpress/wp-includes/js/media-views.js - About 1 hr to fix

      Function complete has 48 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

                      complete: function( next ) {
      
                          // toggle low quality for IE
                          if ( 'image' in active ) {
                              Utils.toggleQuality( active.image, false );
      Severity: Minor
      Found in Web.Admin/Content/galleria/galleria-1.4.2.js - About 1 hr to fix

        Method privExtractFileInOutput has 48 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

          function privExtractFileInOutput(&$p_entry, &$p_options)
          {
            $v_result=1;
        
            // ----- Read the file header
        Severity: Minor
        Found in Web.Admin/2014/wordpress/wp-admin/includes/class-pclzip.php - About 1 hr to fix

          Method install_theme_info has 48 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

              function install_theme_info( $theme ) {
                  global $themes_allowedtags;
          
                  if ( empty( $theme ) )
                      return;

            Method wp_ajax_upload_attachment has 48 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

            function wp_ajax_upload_attachment() {
                check_ajax_referer( 'media-form' );
            
                if ( ! current_user_can( 'upload_files' ) )
                    wp_die();
            Severity: Minor
            Found in Web.Admin/2014/wordpress/wp-admin/includes/ajax-actions.php - About 1 hr to fix

              Method __construct has 48 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  public function __construct($location, $name, $type)
                  {
                      $this->options = array(
                          'user' => null,
                          'pass' => null,
              Severity: Minor
              Found in Web.Admin/2014/wordpress/wp-includes/SimplePie/Cache/MySQL.php - About 1 hr to fix

                Method mod_rewrite_rules has 48 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                    function mod_rewrite_rules() {
                        if ( ! $this->using_permalinks()) {
                            return '';
                        }
                
                
                Severity: Minor
                Found in Web.Admin/2014/wordpress/wp-includes/rewrite.php - About 1 hr to fix

                  Function match has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring.
                  Open

                    match: function(element) {
                      this.tokens = [];
                  
                      var e = this.expression, ps = Selector.patterns, as = Selector.assertions;
                      var le, p, m;
                  Severity: Minor
                  Found in Web.Admin/2014/wordpress/wp-includes/js/prototype.js - About 1 hr 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 setOpacity has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring.
                  Open

                    Element.Methods.setOpacity = function(element, value) {
                      element = $(element);
                      element.style.opacity = (value == 1 || value === '') ? '' :
                        (value < 0.00001) ? 0 : value;
                  
                  
                  Severity: Minor
                  Found in Web.Admin/2014/wordpress/wp-includes/js/prototype.js - About 1 hr 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 match has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring.
                  Open

                    match: function(element) {
                      this.tokens = [];
                  
                      var e = this.expression, ps = Selector.patterns, as = Selector.assertions;
                      var le, p, m;
                  Severity: Minor
                  Found in Web.Admin/2014/wordpress/wp-includes/js/scriptaculous/prototype.js - About 1 hr 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 dealWithDeprecatedOptions has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring.
                  Open

                  Ajax.InPlaceEditor.prototype.initialize.dealWithDeprecatedOptions = function(options) {
                    if (!options) return;
                    function fallback(name, expr) {
                      if (name in options || expr === undefined) return;
                      options[name] = expr;
                  Severity: Minor
                  Found in Web.Admin/2014/wordpress/wp-includes/js/scriptaculous/controls.js - About 1 hr 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 setOpacity has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring.
                  Open

                    Element.Methods.setOpacity = function(element, value) {
                      element = $(element);
                      element.style.opacity = (value == 1 || value === '') ? '' :
                        (value < 0.00001) ? 0 : value;
                  
                  
                  Severity: Minor
                  Found in Web.Admin/2014/wordpress/wp-includes/js/scriptaculous/prototype.js - About 1 hr 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 onHover has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring.
                  Open

                    onHover: function(element, dropon, overlap) {
                      if(Element.isParent(dropon, element)) return;
                  
                      if(overlap > .33 && overlap < .66 && Sortable.options(dropon).tree) {
                        return;
                  Severity: Minor
                  Found in Web.Admin/2014/wordpress/wp-includes/js/scriptaculous/dragdrop.js - About 1 hr 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 draw has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring.
                  Open

                    draw: function(point) {
                      var pos = Position.cumulativeOffset(this.element);
                      if(this.options.ghosting) {
                        var r   = Position.realOffset(this.element);
                        pos[0] += r[0] - Position.deltaX; pos[1] += r[1] - Position.deltaY;
                  Severity: Minor
                  Found in Web.Admin/2014/wordpress/wp-includes/js/scriptaculous/dragdrop.js - About 1 hr 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 privAddFileList has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring.
                  Open

                    function privAddFileList($p_filedescr_list, &$p_result_list, &$p_options)
                    {
                      $v_result=1;
                      $v_header = array();
                  
                  
                  Severity: Minor
                  Found in Web.Admin/2014/wordpress/wp-admin/includes/class-pclzip.php - About 1 hr 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 login has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring.
                  Open

                      function login($user=NULL, $pass=NULL) {
                          if(!is_null($user)) $this->_login=$user;
                          else $this->_login="anonymous";
                          if(!is_null($pass)) $this->_password=$pass;
                          else $this->_password="anon@anon.com";
                  Severity: Minor
                  Found in Web.Admin/2014/wordpress/wp-admin/includes/class-ftp.php - About 1 hr 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_category_checklist has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring.
                  Open

                  function wp_category_checklist( $post_id = 0, $descendants_and_self = 0, $selected_cats = false, $popular_cats = false, $walker = null, $checked_ontop = true ) {
                      if ( empty($walker) || !is_a($walker, 'Walker') )
                          $walker = new Walker_Category_Checklist;
                  
                      $descendants_and_self = (int) $descendants_and_self;
                  Severity: Minor
                  Found in Web.Admin/2014/wordpress/wp-admin/includes/template.php - About 1 hr 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 wpmu_delete_user has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring.
                  Open

                  function wpmu_delete_user( $id ) {
                      global $wpdb;
                  
                      $id = (int) $id;
                      $user = new WP_User( $id );
                  Severity: Minor
                  Found in Web.Admin/2014/wordpress/wp-admin/includes/ms.php - About 1 hr 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 _settype has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring.
                  Open

                      function _settype($mode=FTP_ASCII) {
                          if($this->_ready) {
                              if($mode==FTP_BINARY) {
                                  if($this->_curtype!=FTP_BINARY) {
                                      if(!$this->_exec("TYPE I", "SetType")) return FALSE;
                  Severity: Minor
                  Found in Web.Admin/2014/wordpress/wp-admin/includes/class-ftp.php - About 1 hr 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