#2298 closed defect (bug) (fixed)
add_role(), capabilties.php typo otherwise plugins might not work as expected
| Reported by: |
|
Owned by: | |
|---|---|---|---|
| Milestone: | Priority: | normal | |
| Severity: | normal | Version: | 2.0 |
| Component: | Administration | Keywords: | add_role, capabilties.php, plugin bg|has-patch bg|commit |
| Focuses: | Cc: |
Description
In wp-includes/capabilities.php
in line 325
is:
return $wp_roles->add_role($role, $display_name, $capabilities = '');
but really should be, since capabilties is really set locally by the functions
return $wp_roles->add_role($role, $display_name, $capabilities);
If not: The third argument of add_role won't work as expected.
Change History (7)
Note: See
TracTickets for help on using
tickets.
The third argument is intended to be optional. See how it is used in populate_roles_160() in wp-admin/upgrade-schema.php.