[wp-trac] [WordPress Trac] #14728: capabilities.php does not include pluggable.php
WordPress Trac
wp-trac at lists.automattic.com
Sun Aug 29 21:27:59 UTC 2010
#14728: capabilities.php does not include pluggable.php
--------------------------+-------------------------------------------------
Reporter: BlaenkDenum | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: General | Version: 3.0.1
Severity: critical | Keywords:
--------------------------+-------------------------------------------------
I have a plugin that calls is_super_admin as defined in capabilities.php.
In multi-site installations, when I enable the plugin, and call
is_super_admin to see if the user is a network admin, I get "Call to
undefined function wp_get_current_user" in capabilities.php on line 1208.
After searching around and trying to fix my plugin, I found a solution
which is to add "require_once('pluggable.php')" to the top of
capabilities.php.
Is this a bug with WordPress? If so, can it be fixed? This fatal error
requires people to have to rename/delete the plugin directory which isn't
all that user-friendly.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/14728>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list