diff --git a/wp-includes/capabilities.php b/wp-includes/capabilities.php index 2ea5aeb488..7d8a00d73b 100644 --- a/wp-includes/capabilities.php +++ b/wp-includes/capabilities.php @@ -829,7 +829,7 @@ function map_meta_cap( $cap, $user_id ) { if ( ! $post_type->map_meta_cap ) { $caps[] = $post_type->cap->$cap; // Prior to 3.1 we would re-call map_meta_cap here. - if ( $cap == 'delete_post' ) + if ( 'delete_post' == $cap ) $cap = $post_type->cap->$cap; break; } @@ -874,7 +874,7 @@ function map_meta_cap( $cap, $user_id ) { if ( ! $post_type->map_meta_cap ) { $caps[] = $post_type->cap->$cap; // Prior to 3.1 we would re-call map_meta_cap here. - if ( $cap == 'edit_post' ) + if ( 'edit_post' == $cap ) $cap = $post_type->cap->$cap; break; } @@ -918,7 +918,7 @@ function map_meta_cap( $cap, $user_id ) { if ( ! $post_type->map_meta_cap ) { $caps[] = $post_type->cap->$cap; // Prior to 3.1 we would re-call map_meta_cap here. - if ( $cap == 'read_post' ) + if ( 'read_post' == $cap ) $cap = $post_type->cap->$cap; break; }