Apple Pay button does nothing on nytimes.com
https://bugs.webkit.org/show_bug.cgi?id=167664
rdar://problem/30273885
Reviewed by Sam Weinig.
Source/WebCore:
Separate line item validation into convertAndValidateTotal and convertAndValidate. The former
works on totals (which require an amount), and the latter works on regular line items that do not require an amount
if the item type is "pending".
* Modules/applepay/ApplePaySession.cpp:
(WebCore::convertAndValidateTotal):
(WebCore::convertAndValidate):
Only check the amount if the type is not pending.
(WebCore::ApplePaySession::completeShippingMethodSelection):
(WebCore::ApplePaySession::completeShippingContactSelection):
(WebCore::ApplePaySession::completePaymentMethodSelection):
Call convertAndValidateTotal for totals.
LayoutTests:
Add a new test.
* http/tests/ssl/applepay/ApplePaySession-expected.txt:
* http/tests/ssl/applepay/ApplePaySession.html:
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@211446 268f45cc-cd09-0410-ab3c-d52691b4dbfc
5 files changed