Don't show apple pay if not supported
This commit is contained in:
parent
d6efea0080
commit
2417005b23
1 changed files with 2 additions and 5 deletions
|
|
@ -137,11 +137,8 @@
|
|||
$(function() {
|
||||
// Check the availability of the Payment Request API first.
|
||||
paymentRequest.canMakePayment().then(function(result) {
|
||||
if (result) {
|
||||
// do nothing
|
||||
} else {
|
||||
console.log('not supported');
|
||||
$('#paymentButtons ul.dropdown-menu li').last().remove();
|
||||
if (! result) {
|
||||
$('#paymentButtons ul.dropdown-menu li').find('a[href$="apple_pay"]').remove();
|
||||
}
|
||||
});
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue