[REST API] Fixed order note ID type

This commit is contained in:
Claudio Sanches 2016-05-23 17:50:04 -03:00
parent a02ac79339
commit 7bda004126
1 changed files with 1 additions and 1 deletions

View File

@ -310,7 +310,7 @@ class WC_REST_Order_Notes_Controller extends WC_REST_Controller {
*/ */
public function prepare_item_for_response( $note, $request ) { public function prepare_item_for_response( $note, $request ) {
$data = array( $data = array(
'id' => $note->comment_ID, 'id' => (int) $note->comment_ID,
'date_created' => wc_rest_prepare_date_response( $note->comment_date_gmt ), 'date_created' => wc_rest_prepare_date_response( $note->comment_date_gmt ),
'note' => $note->comment_content, 'note' => $note->comment_content,
'customer_note' => (bool) get_comment_meta( $note->comment_ID, 'is_customer_note', true ), 'customer_note' => (bool) get_comment_meta( $note->comment_ID, 'is_customer_note', true ),