diff --git a/includes/abstracts/abstract-wc-order.php b/includes/abstracts/abstract-wc-order.php index 1124c897b4e..6cdd71f41c7 100644 --- a/includes/abstracts/abstract-wc-order.php +++ b/includes/abstracts/abstract-wc-order.php @@ -37,7 +37,7 @@ * @property string $shipping_method_title < 2.1 was used for shipping method title. Now @deprecated. * @property int $customer_user User ID who the order belongs to. 0 for guests. * @property string $order_key Random key/password unqique to each order. - * @property string $order_discount. Stored after tax discounts pre-2.3. Now @deprecated. + * @property string $order_discount Stored after tax discounts pre-2.3. Now @deprecated. * @property string $order_tax Stores order tax total. * @property string $order_shipping_tax Stores shipping tax total. * @property string $order_shipping Stores shipping total. @@ -108,8 +108,7 @@ abstract class WC_Abstract_Order { /** * Init/load the order object. Called from the constructor. * - * @var WP_Post - * @param int|WP_Post|WC_Order $order Order to init + * @param int|object|WC_Order $order Order to init */ protected function init( $order ) { if ( is_numeric( $order ) ) { @@ -120,7 +119,7 @@ abstract class WC_Abstract_Order { $this->id = absint( $order->id ); $this->post = $order->post; $this->get_order( $this->id ); - } elseif ( $order instanceof WP_Post || isset( $order->ID ) ) { + } elseif ( isset( $order->ID ) { $this->id = absint( $order->ID ); $this->post = $order; $this->get_order( $this->id ); diff --git a/includes/abstracts/abstract-wc-product.php b/includes/abstracts/abstract-wc-product.php index 5b2986fb0bb..3bdf38e1052 100644 --- a/includes/abstracts/abstract-wc-product.php +++ b/includes/abstracts/abstract-wc-product.php @@ -59,8 +59,7 @@ class WC_Product { /** * Constructor gets the post object and sets the ID for the loaded product. * - * @param int|WC_Product|WP_Post $product Product ID, post object, or product object - * @var WP_POST + * @param int|WC_Product|object $product Product ID, post object, or product object */ public function __construct( $product ) { if ( is_numeric( $product ) ) { @@ -69,7 +68,7 @@ class WC_Product { } elseif ( $product instanceof WC_Product ) { $this->id = absint( $product->id ); $this->post = $product->post; - } elseif ( $product instanceof WP_Post || isset( $product->ID ) ) { + } elseif ( isset( $product->ID ) ) { $this->id = absint( $product->ID ); $this->post = $product; } diff --git a/includes/admin/meta-boxes/views/html-order-fee.php b/includes/admin/meta-boxes/views/html-order-fee.php index 9ba95317e0b..2b2c4476fd7 100644 --- a/includes/admin/meta-boxes/views/html-order-fee.php +++ b/includes/admin/meta-boxes/views/html-order-fee.php @@ -2,8 +2,8 @@ /** * Shows an order item fee * - * @var int $item_id The id of the item being displayed - * @var object $item The item being displayed + * @var $item_id int The id of the item being displayed + * @var $item object The item being displayed */ if ( ! defined( 'ABSPATH' ) ) { exit;