You appear to be a bot. Output may be restricted
Description
Increase the purchase count of a customer
Usage
$int = EDD_Customer::increase_purchase_count( $count );
Parameters
- $count
- ( integer ) optional default: 1 – The number to imcrement by
Returns
int The purchase count
Source
File name: easy-digital-downloads/includes/class-edd-customer.php
Lines:
1 to 19 of 19
public function increase_purchase_count( $count = 1 ) { // Make sure it's numeric and not negative if ( ! is_numeric( $count ) || $count != absint( $count ) ) { return false; } $new_total = (int) $this->purchase_count + (int) $count; do_action( 'edd_customer_pre_increase_purchase_count', $count, $this->id, $this ); if ( $this->update( array( 'purchase_count' => $new_total ) ) ) { $this->purchase_count = $new_total; } do_action( 'edd_customer_post_increase_purchase_count', $this->purchase_count, $count, $this->id, $this ); return $this->purchase_count; }