Change \WC_Order::add_order_note cap to edit_shop_order instead of manage_woocommerce

This commit is contained in:
Mike 2014-04-03 14:33:54 +02:00
parent 342737907a
commit 16463e339e
1 changed files with 1 additions and 1 deletions

View File

@ -1250,7 +1250,7 @@ class WC_Order {
$is_customer_note = intval( $is_customer_note );
if ( is_user_logged_in() && current_user_can( 'manage_woocommerce' ) ) {
if ( is_user_logged_in() && current_user_can( 'edit_shop_order', $this->id ) ) {
$user = get_user_by( 'id', get_current_user_id() );
$comment_author = $user->display_name;
$comment_author_email = $user->user_email;