private function extractSales($transactions) {
		$out = [];
		
		foreach ($transactions as $trx) {
			foreach ($trx->related_resources as $src) {
				if (isset($src->sale)) {
					$out[] = $src->sale;
				}
			}
		}
		
		return $out;
	}
private function extractSales($transactions) {
		$out = [];
		
		foreach ($transactions as $trx) {
			foreach ($trx->related_resources as $src) {
				if (isset($src->sale)) {
					$out[] = $src->sale;
				}
			}
		}
		
		return $out;
	}
private function extractSales ( $ transactions ) { $ out = [ ] ; foreach ( $ transactions as $ trx ) { foreach ( $ trx -> related_resources as $ src ) { if ( isset ( $ src -> sale ) ) { $ out [ ] = $ src -> sale ; } } } return $ out ; }
Parse PayPal "transactions" list from execution approval call
and extract the "sale" objects which contain the refund URLs
@param object $transactions
Parse PayPal transactions list from execution approval call and extract the sale objects which contain the refund URLs