Automattic\WooCommerce\Internal\DataStores\Orders

OrdersTableDataStore::get_email_sent()publicWC 1.0

Whether email have been sent for this order.

Method of the class: OrdersTableDataStore{}

No Hooks.

Return

true|false. Whether email is sent.

Usage

$OrdersTableDataStore = new OrdersTableDataStore();
$OrdersTableDataStore->get_email_sent( $order );
$order(\WC_Order|int) (required)
Order object.

OrdersTableDataStore::get_email_sent() code WC 9.3.3

public function get_email_sent( $order ) {
	$order_id = is_int( $order ) ? $order : $order->get_id();
	$order    = wc_get_order( $order_id );
	return $order->get_new_order_email_sent();
}