WordPress.org

Make WordPress Core

Ticket #16034: garyc40-16034-rev2.patch

File garyc40-16034-rev2.patch, 724 bytes (added by garyc40, 3 years ago)

reverted to using blog_id instead of registered, use is_subdomain_install()

  • wp-admin/includes/class-wp-ms-sites-list-table.php

    diff --git wp-admin/includes/class-wp-ms-sites-list-table.php wp-admin/includes/class-wp-ms-sites-list-table.php
    index 7931d6d..45eff56 100644
    class WP_MS_Sites_List_Table extends WP_List_Table { 
    8484                } elseif ( $order_by == 'lastupdated' ) { 
    8585                        $query .= ' ORDER BY last_updated '; 
    8686                } elseif ( $order_by == 'blogname' ) { 
    87                         $query .= ' ORDER BY domain '; 
     87                        if ( is_subdomain_install() ) { 
     88                                $query .= ' ORDER BY domain '; 
     89                        } else { 
     90                                $query .= ' ORDER BY path '; 
     91                        } 
     92                } elseif ( $order_by == 'id' ) { 
     93                        $query .= ' ORDER BY blog_id '; 
    8894                } else { 
    8995                        $order_by = null; 
    9096                }