[wp-trac] [WordPress Trac] #17829: Site Admin goes to User Admin if user has no sites

WordPress Trac wp-trac at lists.automattic.com
Sun Jun 19 21:46:21 UTC 2011


#17829: Site Admin goes to User Admin if user has no sites
------------------------------+-----------------------
 Reporter:  trepmal           |       Owner:  nacin
     Type:  defect (bug)      |      Status:  accepted
 Priority:  normal            |   Milestone:  3.2
Component:  Network Admin     |     Version:  3.1
 Severity:  normal            |  Resolution:
 Keywords:  has-patch commit  |
------------------------------+-----------------------
Changes (by nacin):

 * keywords:  has-patch => has-patch commit


Comment:

 We need a better function than get_blogs_of_user() that provides us
 boolean values as to whether someone has a blog. Without object caching
 that function really stinks cause it runs a lot of cross-blog queries.

 Regardless, that patch looks good for 3.2. Would rather it be prettied a
 little -- if were are to do `else { }` when we also need to do brackets
 around the first if statement.

 Likewise `$links[10]` needs an extra indent and the empty lines after the
 `else` and before the `$links[10]` assignment aren't really needed.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/17829#comment:3>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list