You appear to be a bot. Output may be restricted
Description
Specific Download
Usage
$void = EDD_Payments_Query::download();
Parameters
Returns
void
Source
File name: easy-digital-downloads/includes/payments/class-payments-query.php
Lines:
1 to 46 of 46
public function download() { if ( empty( $this->args['download'] ) ) return; global $edd_logs; $args = array( 'post_parent' => $this->args['download'], 'log_type' => 'sale', 'post_status' => array( 'publish' ), 'nopaging' => true, 'no_found_rows' => true, 'update_post_term_cache' => false, 'update_post_meta_cache' => false, 'cache_results' => false, 'fields' => 'ids' ); if ( is_array( $this->args['download'] ) ) { unset( $args['post_parent'] ); $args['post_parent__in'] = $this->args['download']; } $sales = $edd_logs->get_connected_logs( $args ); if ( ! empty( $sales ) ) { $payments = array(); foreach ( $sales as $sale ) { $payments[] = get_post_meta( $sale, '_edd_log_payment_id', true ); } $this->__set( 'post__in', $payments ); } else { // Set post_parent to something crazy so it doesn't find anything $this->__set( 'post_parent', 999999999999999 ); } $this->__unset( 'download' ); }