- From: Matt Giuca <notifications@github.com>
- Date: Wed, 19 Oct 2016 21:38:08 -0700
- To: w3c/manifest <manifest@noreply.github.com>
- Message-ID: <w3c/manifest/issues/417/255007189@github.com>
I think I prefer the old behaviour -- `userChoice` would be left unresolved in the case of a `prompt` error. Leaving promises unresolved isn't a bad thing: it just means that the conditions to resolve them weren't met. I don't see a strong relation between a `prompt` error and `userChoice`; in fact you can still successfully make a choice after a prompt error. For example: ```js window.addEventListener('beforeinstallprompt', () => { try { e.prompt(); // Error: preventDefault not called } catch (e) {} e.preventDefault(); e.prompt(); // This is fine. }); ``` It would be bad to reject `userChoice` on the first prompt, because it's still meaningful later. In fact, just this: ```js window.addEventListener('beforeinstallprompt', () => { e.prompt(); }); ``` It's going to continue with the automatic prompt after that. `userChoice` should not be rejected by the call to `prompt()`. -- 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/manifest/issues/417#issuecomment-255007189
Received on Thursday, 20 October 2016 04:38:41 UTC