CaffGeek/MBACNationals

View on GitHub

Showing 5,566 of 7,504 total issues

Consider simplifying this complex logical expression.
Open

if ( isset($_GET['doaction']) || isset($_GET['doaction2']) || isset($_GET['delete_all']) || isset($_GET['delete_all2']) || isset($_GET['bulk_edit']) ) {
    check_admin_referer('bulk-pages');
    $sendback = remove_query_arg( array('trashed', 'untrashed', 'deleted', 'ids'), wp_get_referer() );

    if ( strpos($sendback, 'page.php') !== false )
Severity: Major
Found in Web.Admin/2014/wordpress/wp-admin/edit-pages.php - About 40 mins to fix

    Consider simplifying this complex logical expression.
    Open

    if ( isset($_GET['approved']) || isset($_GET['deleted']) || isset($_GET['trashed']) || isset($_GET['untrashed']) || isset($_GET['spammed']) || isset($_GET['unspammed']) ) {
        $approved = isset($_GET['approved']) ? (int) $_GET['approved'] : 0;
        $deleted = isset($_GET['deleted']) ? (int) $_GET['deleted'] : 0;
        $trashed = isset($_GET['trashed']) ? (int) $_GET['trashed'] : 0;
        $untrashed = isset($_GET['untrashed']) ? (int) $_GET['untrashed'] : 0;
    Severity: Major
    Found in Web.Admin/2014/wordpress/wp-admin/edit-comments.php - About 40 mins to fix

      Consider simplifying this complex logical expression.
      Open

              if ('family' == $class && strpos($link_rel, 'child') === false && strpos($link_rel, 'parent') === false && strpos($link_rel, 'sibling') === false && strpos($link_rel, 'spouse') === false && strpos($link_rel, 'kin') === false) echo ' checked="checked"';
      Severity: Major
      Found in Web.Admin/2014/wordpress/wp-admin/includes/meta-boxes.php - About 40 mins to fix

        Consider simplifying this complex logical expression.
        Open

                        } else if ( (isset($plugin_page) && $plugin_page == $sub_item[2] && (!file_exists($menu_file) || ($item[2] == $self))) || (!isset($plugin_page) && $self == $sub_item[2]) ) {
                            $class[] = 'current';
                        }
        Severity: Major
        Found in Web.Admin/2014/wordpress/wp-admin/menu-header.php - About 40 mins to fix

          Consider simplifying this complex logical expression.
          Open

                          if ( ( ('index.php' != $sub_item[2]) && file_exists(WP_PLUGIN_DIR . "/$sub_file") ) || ! empty($menu_hook) ) {
                              // If admin.php is the current page or if the parent exists as a file in the plugins or admin dir
          
                              $parent_exists = (!$admin_is_parent && file_exists(WP_PLUGIN_DIR . "/$menu_file") && !is_dir(WP_PLUGIN_DIR . "/{$item[2]}") ) || file_exists($menu_file);
                              if ( $parent_exists )
          Severity: Major
          Found in Web.Admin/2014/wordpress/wp-admin/menu-header.php - About 40 mins to fix

            Consider simplifying this complex logical expression.
            Open

            if ( isset($_GET['find_detached']) ) {
                check_admin_referer('bulk-media');
            
                if ( !current_user_can('edit_posts') )
                    wp_die( __('You are not allowed to scan for lost attachments.') );
            Severity: Major
            Found in Web.Admin/2014/wordpress/wp-admin/upload.php - About 40 mins to fix

              Consider simplifying this complex logical expression.
              Open

              if ( isset($_GET['doaction']) || isset($_GET['doaction2']) || isset($_GET['delete_all']) || isset($_GET['delete_all2']) || isset($_GET['bulk_edit']) ) {
                  check_admin_referer('bulk-posts');
                  $sendback = remove_query_arg( array('trashed', 'untrashed', 'deleted', 'ids'), wp_get_referer() );
              
                  if ( strpos($sendback, 'post.php') !== false )
              Severity: Major
              Found in Web.Admin/2014/wordpress/wp-admin/edit.php - About 40 mins to fix

                Consider simplifying this complex logical expression.
                Open

                    if ( !get_option('wordpress_api_key') && !$wpcom_api_key && !isset($_POST['submit']) ) {
                        function akismet_warning() {
                            echo "
                            <div id='akismet-warning' class='updated fade'><p><strong>".__('Akismet is almost ready.')."</strong> ".sprintf(__('You must <a href="%1$s">enter your WordPress.com API key</a> for it to work.'), "plugins.php?page=akismet-key-config")."</p></div>
                            ";
                Severity: Major
                Found in Web.Admin/2014/wordpress/wp-content/plugins/akismet/akismet.php - About 40 mins to fix

                  Consider simplifying this complex logical expression.
                  Open

                          if (
                                 preg_match($pattern, $author)
                              || preg_match($pattern, $email)
                              || preg_match($pattern, $url)
                              || preg_match($pattern, $comment)
                  Severity: Major
                  Found in Web.Admin/2014/wordpress/wp-includes/comment.php - About 40 mins to fix

                    Consider simplifying this complex logical expression.
                    Open

                    <?php if ( isset($_GET['locked']) || isset($_GET['skipped']) || isset($_GET['updated']) || isset($_GET['deleted']) || isset($_GET['trashed']) || isset($_GET['untrashed']) ) { ?>
                    <div id="message" class="updated fade"><p>
                    <?php if ( isset($_GET['updated']) && (int) $_GET['updated'] ) {
                        printf( _n( '%s post updated.', '%s posts updated.', $_GET['updated'] ), number_format_i18n( $_GET['updated'] ) );
                        unset($_GET['updated']);
                    Severity: Major
                    Found in Web.Admin/2014/wordpress/wp-admin/edit.php - About 40 mins to fix

                      Consider simplifying this complex logical expression.
                      Open

                                  if ( is_user_logged_in() && ( $active_signup == 'all' || $active_signup == 'blog' ) )
                                      signup_another_blog($newblogname);
                                  elseif ( is_user_logged_in() == false && ( $active_signup == 'all' || $active_signup == 'user' ) )
                                      signup_user( $newblogname, $user_email );
                                  elseif ( is_user_logged_in() == false && ( $active_signup == 'blog' ) )
                      Severity: Major
                      Found in Web.Admin/2014/wordpress/wp-signup.php - About 40 mins to fix

                        Consider simplifying this complex logical expression.
                        Open

                            if ( !$secure_cookie && is_ssl() && force_ssl_login() && !force_ssl_admin() && ( 0 !== strpos($redirect_to, 'https') ) && ( 0 === strpos($redirect_to, 'http') ) )
                                $secure_cookie = false;
                        Severity: Major
                        Found in Web.Admin/2014/wordpress/wp-login.php - About 40 mins to fix

                          Consider simplifying this complex logical expression.
                          Open

                                  if (     stripos($plugin['Name'], $term) !== false ||
                                          stripos($plugin['Description'], $term) !== false ||
                                          stripos($plugin['Author'], $term) !== false ||
                                          stripos($plugin['PluginURI'], $term) !== false ||
                                          stripos($plugin['AuthorURI'], $term) !== false ||
                          Severity: Major
                          Found in Web.Admin/2014/wordpress/wp-admin/plugins.php - About 40 mins to fix

                            Consider simplifying this complex logical expression.
                            Open

                                        if ( $new_status == 'spam' && ( $old_status == 'approved' || $old_status == 'unapproved' || !$old_status ) ) {
                                            return self::submit_spam_comment( $comment->comment_ID );
                                        } elseif ( $old_status == 'spam' && ( $new_status == 'approved' || $new_status == 'unapproved' ) ) {
                                            return self::submit_nonspam_comment( $comment->comment_ID );
                                        }

                              Consider simplifying this complex logical expression.
                              Open

                                  if        ( isset($_GET['loggedout']) && TRUE == $_GET['loggedout'] )
                                      $errors->add('loggedout', __('You are now logged out.'), 'message');
                                  elseif    ( isset($_GET['registration']) && 'disabled' == $_GET['registration'] )
                                      $errors->add('registerdisabled', __('User registration is currently not allowed.'));
                                  elseif    ( isset($_GET['checkemail']) && 'confirm' == $_GET['checkemail'] )
                              Severity: Major
                              Found in Web.Admin/2014/wordpress/wp-login.php - About 40 mins to fix

                                Consider simplifying this complex logical expression.
                                Open

                                    if ( isset($_POST['trash']) && 1 == $_POST['trash'] ) {
                                        if ( 'trash' == $status )
                                            die( (string) time() );
                                        $r = wp_trash_comment( $comment->comment_ID );
                                    } elseif ( isset($_POST['untrash']) && 1 == $_POST['untrash'] ) {
                                Severity: Major
                                Found in Web.Admin/2014/wordpress/wp-admin/admin-ajax.php - About 40 mins to fix

                                  Consider simplifying this complex logical expression.
                                  Open

                                      if ( is_object($wp_rewrite) && $wp_rewrite->using_permalinks() && !is_404() && (!is_front_page() || ( is_front_page() && (get_query_var('paged') > 1) ) ) ) {
                                          $user_ts_type = '';
                                          if ( get_query_var('paged') > 0 ) {
                                              $user_ts_type = 'paged';
                                          } else {
                                  Severity: Major
                                  Found in Web.Admin/2014/wordpress/wp-includes/canonical.php - About 40 mins to fix

                                    Consider simplifying this complex logical expression.
                                    Open

                                                    if ($feed->success && ($feed->method & SIMPLEPIE_FILE_SOURCE_REMOTE === 0 || ($feed->status_code === 200 || $feed->status_code > 206 && $feed->status_code < 300)) && $this->is_feed($feed))
                                                    {
                                                        return $feed;
                                                    }
                                                    else
                                    Severity: Major
                                    Found in Web.Admin/2014/wordpress/wp-includes/SimplePie/Locator.php - About 40 mins to fix

                                      Consider simplifying this complex logical expression.
                                      Open

                                              if (
                                                  $name === 'iri' ||
                                                  $name === 'uri' ||
                                                  $name === 'iauthority' ||
                                                  $name === 'authority'
                                      Severity: Major
                                      Found in Web.Admin/2014/wordpress/wp-includes/SimplePie/IRI.php - About 40 mins to fix

                                        Consider simplifying this complex logical expression.
                                        Open

                                                            if ($feed->success && ($feed->method & SIMPLEPIE_FILE_SOURCE_REMOTE === 0 || ($feed->status_code === 200 || $feed->status_code > 206 && $feed->status_code < 300)) && $this->is_feed($feed))
                                                            {
                                                                $feeds[$href] = $feed;
                                                            }
                                        Severity: Major
                                        Found in Web.Admin/2014/wordpress/wp-includes/SimplePie/Locator.php - About 40 mins to fix
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language