• Rouslan Solomakhin's avatar
    [Payments] More verbose 'payment method not supported' message. · b07da295
    Rouslan Solomakhin authored
    Before this patch, PaymentRequest.show() could reject with "Payment
    method not supported" message, which did not clarify which payment
    methods were not supported. This could be debugging confusing in a large
    production environment, where multiple PaymentRequest instances with
    different payment method names are created.
    
    This patch stores the set of payment method names for each instance of
    PaymentRequest and prints them out in the error message, if none of them
    are supported.
    
    After this patch, PaymentRequest.show() can reject with error message
    "Payment method 'xyz' is not supported". (Plurals are handled
    correctly.)
    
    Bug: 785992
    Change-Id: I976b11b84f788ea98b4e413ca983edd8f792052d
    Reviewed-on: https://chromium-review.googlesource.com/775045Reviewed-by: default avatarMarijn Kruisselbrink <mek@chromium.org>
    Commit-Queue: Rouslan Solomakhin <rouslan@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#517243}
    b07da295
PaymentRequest.h 4.97 KB