Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(862)

Unified Diff: third_party/WebKit/Source/modules/payments/PaymentRequest.cpp

Issue 1981903002: PaymentRequest: Rename 'currencyCode' to 'currency' in CurrencyAmount.idl. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/modules/payments/PaymentRequest.cpp
diff --git a/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp b/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp
index a406722453f5f1952f3440084a4c87702f846527..152e6de577e1d7a25a340324561f48f941fd49e5 100644
--- a/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp
+++ b/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp
@@ -45,7 +45,7 @@ struct TypeConverter<CurrencyAmountPtr, blink::CurrencyAmount> {
static CurrencyAmountPtr Convert(const blink::CurrencyAmount& input)
{
CurrencyAmountPtr output = CurrencyAmount::New();
- output->currency_code = input.currencyCode();
+ output->currency_code = input.currency();
output->value = input.value();
return output;
}
@@ -125,7 +125,7 @@ void validateShippingOptionsOrPaymentItems(HeapVector<T> items, ExceptionState&
return;
}
- if (!item.amount().hasCurrencyCode()) {
+ if (!item.amount().hasCurrency()) {
exceptionState.throwTypeError("Currency code required");
return;
}
@@ -135,7 +135,7 @@ void validateShippingOptionsOrPaymentItems(HeapVector<T> items, ExceptionState&
return;
}
- if (!PaymentsValidators::isValidCurrencyCodeFormat(item.amount().currencyCode(), &errorMessage)) {
+ if (!PaymentsValidators::isValidCurrencyCodeFormat(item.amount().currency(), &errorMessage)) {
exceptionState.throwTypeError(errorMessage);
return;
}

Powered by Google App Engine
This is Rietveld 408576698