Skip to content

Commit

Permalink
211, currentTotal variable is used till 4.6, therefore retrieved data…
Browse files Browse the repository at this point in the history
… stored in priceValue

211, currentTotal variable is used till 4.6, therefore retrieved data stored in priceValue

--fixed typeof

--fixed code
  • Loading branch information
pradpnayak committed Apr 29, 2017
1 parent a8d3db6 commit 4646204
Showing 1 changed file with 6 additions and 8 deletions.
14 changes: 6 additions & 8 deletions js/civicrm_stripe.js
Original file line number Diff line number Diff line change
Expand Up @@ -151,14 +151,12 @@
// Hide payment if total is 0 and no more participants.
if ($('#priceset').length) {
additionalParticipants = cj("#additional_participants").val();
// The currentTotal is already being calculated in Form/Contribution/Main.tpl.
if(typeof currentTotal !== 'undefined') {
if (currentTotal == 0 && !additionalParticipants) {
// This is also hit when "Going back", but we already have stripe_token.
debugging('ozlkf');
// This should not happen on Confirm Contribution, but seems to on 4.6 for some reason.
//return true;
}
currentTotal = $('#pricevalue').data('raw-total');
if (currentTotal == 0 && !additionalParticipants) {
// This is also hit when "Going back", but we already have stripe_token.
debugging('ozlkf');
// This should not happen on Confirm Contribution, but seems to on 4.6 for some reason.
//return true;
}
}

Expand Down

0 comments on commit 4646204

Please sign in to comment.