phpcs fixes in includes/data-stores/abstract-wc-order-data-store-cpt.php
This commit is contained in:
parent
4ef9e8d725
commit
03c202f1f5
|
@ -13,8 +13,6 @@ if ( ! defined( 'ABSPATH' ) ) {
|
|||
* Abstract Order Data Store: Stored in CPT.
|
||||
*
|
||||
* @version 3.0.0
|
||||
* @category Class
|
||||
* @author WooThemes
|
||||
*/
|
||||
abstract class Abstract_WC_Order_Data_Store_CPT extends WC_Data_Store_WP implements WC_Object_Data_Store_Interface, WC_Abstract_Order_Data_Store_Interface {
|
||||
|
||||
|
@ -98,7 +96,7 @@ abstract class Abstract_WC_Order_Data_Store_CPT extends WC_Data_Store_WP impleme
|
|||
$order->set_defaults();
|
||||
$post_object = get_post( $order->get_id() );
|
||||
|
||||
if ( ! $order->get_id() || ! $post_object || ! in_array( $post_object->post_type, wc_get_order_types() ) ) {
|
||||
if ( ! $order->get_id() || ! $post_object || ! in_array( $post_object->post_type, wc_get_order_types(), true ) ) {
|
||||
throw new Exception( __( 'Invalid order.', 'woocommerce' ) );
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue