[wp-trac] [WordPress Trac] #15829: Admin Bar on/off preferences
WordPress Trac
wp-trac at lists.automattic.com
Fri Dec 17 16:05:03 UTC 2010
#15829: Admin Bar on/off preferences
--------------------------------+-----------------------
Reporter: jane | Owner: duck_
Type: task (blessed) | Status: assigned
Priority: normal | Milestone: 3.1
Component: Administration | Version: 3.1
Severity: normal | Resolution:
Keywords: admin bar, options |
--------------------------------+-----------------------
Comment (by duck_):
Replying to [comment:6 duck_]:
> `15829.001.diff` attached. Works around the problem of existing users
and the default settings by changing the option strings as required...
however this does make it quite messy, so another solution (if there
someone can think of one) is probably preferable. Another note is the user
of non-short-circuiting `|` to avoid undefined notice, probably want to
either change this to calling each filter again or assign the filter
results before the first conditional for clarity.
Just noticed that I '''think''' the code in wp-admin/includes/user.php can
be cut down a bit since wp_update_user will perform a merge with old data,
so only need to set $user->admin_bar_pref_* when
apply_filters('show_admin_bar_pref_front', true) == true
--
Ticket URL: <http://core.trac.wordpress.org/ticket/15829#comment:7>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list