Skip to content

Commit a5813ee

Browse files
committed
Log message if CRM.vars.omnipay are not defined instead of trying to load checkout
1 parent a0d5473 commit a5813ee

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

Metadata/js/omnipay_PaypalRest.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,11 @@
33
var form = $('#billing-payment-block').closest('form');
44
var qfKey = $('[name=qfKey]', form).val();
55

6+
if (typeof CRM.vars.omnipay === 'undefined') {
7+
console.log('CRM.vars.omnipay not defined! Not a Omnipay processor?');
8+
return;
9+
}
10+
611
function renderPaypal() {
712
paypal.Buttons({
813

0 commit comments

Comments
 (0)