From 2417005b23d5a5788cea6718f3d43b94f4299ab6 Mon Sep 17 00:00:00 2001 From: Hillel Coren Date: Mon, 15 Jan 2018 22:45:18 +0200 Subject: [PATCH] Don't show apple pay if not supported --- resources/views/invoices/view.blade.php | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/resources/views/invoices/view.blade.php b/resources/views/invoices/view.blade.php index dfc2d2d107e0..a06b97991932 100644 --- a/resources/views/invoices/view.blade.php +++ b/resources/views/invoices/view.blade.php @@ -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(); } });