Customer::get_order_count()
Summary
Get amount of orders for the customer
Return
(int)
Source
File: src/BigCommerce/Accounts/Customer.php
public function get_order_count() { $customer_id = $this->get_customer_id(); if ( ! $customer_id ) { return 0; } try { $count = Client::getOrdersCount( [ 'customer_id' => $customer_id, ] ); return (int) $count; } catch ( \Exception $e ) { return 0; } }