Introduce assign_cap for Taxonomies, Defaults to 'edit_posts'. Allows for Authors/Contributors to tag/categorise their posts. See #12035
git-svn-id: http://svn.automattic.com/wordpress/trunk@13289 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
@@ -208,7 +208,7 @@ function _wp_ajax_add_hierarchical_term() {
|
||||
$action = $_POST['action'];
|
||||
$taxonomy = get_taxonomy(substr($action, 4));
|
||||
check_ajax_referer( $action );
|
||||
if ( !current_user_can( $taxonomy->manage_cap ) )
|
||||
if ( !current_user_can( $taxonomy->edit_cap ) )
|
||||
die('-1');
|
||||
$names = explode(',', $_POST['new'.$taxonomy->name]);
|
||||
$parent = isset($_POST['new'.$taxonomy->name.'_parent']) ? (int) $_POST['new'.$taxonomy->name.'_parent'] : 0;
|
||||
|
||||
Reference in New Issue
Block a user