Skip to content

Commit

Permalink
Merge branch 'hotfix/PB-930'
Browse files Browse the repository at this point in the history
  • Loading branch information
LukaszKurpanik committed Jun 4, 2024
2 parents 3c93a25 + cc4adf7 commit 2fa041b
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions includes/cart/actions.php
Original file line number Diff line number Diff line change
Expand Up @@ -65,9 +65,10 @@ function edd_process_cart_endpoints() {
*/
function edd_process_add_to_cart( $data ) {
$download_id = absint( $data['download_id'] );
$options = isset( $data['edd_options'] ) ? $data['edd_options'] : array();

if ( ! empty( $data['edd_download_quantity'] ) ) {
$options = (isset($data['edd_options']) && is_array($data['edd_options'])) ? $data['edd_options'] : array();

if ( ! empty( $data['edd_download_quantity'] ) ) {
$options['quantity'] = absint( $data['edd_download_quantity'] );
}

Expand Down

0 comments on commit 2fa041b

Please sign in to comment.