Chromium Code Reviews| 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 0adcb7c08c18fef7a5854aad5bb668a64e8c21d6..ff678986c1c434db7b00911917e9f7e6ccc0cb75 100644 |
| --- a/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp |
| +++ b/third_party/WebKit/Source/modules/payments/PaymentRequest.cpp |
| @@ -125,6 +125,11 @@ struct TypeConverter<PaymentDetailsPtr, blink::PaymentDetails> { |
| else |
| output->modifiers = mojo::WTFArray<PaymentDetailsModifierPtr>::New(0); |
| + if (input.hasError()) |
| + output->error = input.error(); |
| + else |
| + output->error = WTF::String(""); |
|
haraken
2016/09/20 14:46:53
WTF::emptyString() ?
Hwanseung Lee
2016/09/20 15:08:44
it is my intention. thank you.
|
| + |
| return output; |
| } |
| }; |
| @@ -519,6 +524,11 @@ PaymentRequest::PaymentRequest(ScriptState* scriptState, const HeapVector<Paymen |
| if (exceptionState.hadException()) |
| return; |
| + if (details.hasError() && !details.error().isEmpty()) { |
| + exceptionState.throwTypeError("must be Error value empty"); |
|
please use gerrit instead
2016/09/20 15:40:50
"Error value should be empty"
Hwanseung Lee
2016/09/20 16:01:09
Done.
|
| + return; |
| + } |
| + |
| if (m_options.requestShipping()) |
| m_shippingOption = getSelectedShippingOption(details); |