- From: Marcos Cáceres <notifications@github.com>
- Date: Thu, 17 Nov 2016 18:21:50 -0800
- To: w3c/browser-payment-api <browser-payment-api@noreply.github.com>
- Message-ID: <w3c/browser-payment-api/pull/316/review/9159474@github.com>
marcoscaceres commented on this pull request. > @@ -523,6 +524,60 @@ </li> </ol> </section> + <section> + <h2> + <code>canMakeActivePayment()</code> method + </h2> + <p> + The <dfn>canMakeActivePayment</dfn> method is called when the page wants to know if the user has a payment method available to use for payment before calling <a data-lt="PaymentRequest.show">show</a>. The <a>canMakeActivePayment</a> method returns a <a>Promise</a> that will be resolved when the <a>user agent</a> has determined if at least one method is available from <a>supportedMethods</a> data. In order to prevent the page from probing different payment methods supported by user, <a>canMakeActivePayment</a> can only be called once per top-level domain. Multiple calls to <a>canMakeActivePayment</a> will result in cached response from previous call. To reduce privacy risks, user agents MAY limit calls to <a>canMakeActivePayment</a> for a certain time before invalidating the cached response per top-level domain. Developers can call <a>canMakeActivePayment</a> multiple times with same set of <a>supportedMethods</a> per top-level domain. + </p> + <p> + The <a>canMakeActivePayment</a> method MUST act as follows: + </p> + <ol> + <li> + Let <var>request</var> be the <a>PaymentRequest</a> object on which the method is called. + </li> + <li>If the value of <var>request</var>@[[\state]] is not "created", then Agree, but like you said, it's confusing to anyone not familiar with WebIDL's behavior... we need clean this up also throughout the spec to adhere more closely to: https://www.w3.org/2001/tag/doc/promises-guide. -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/w3c/browser-payment-api/pull/316
Received on Friday, 18 November 2016 02:22:23 UTC