- From: Mounir Lamouri <mounir@lamouri.fr>
- Date: Tue, 01 Jul 2014 20:03:53 +1000
- To: public-device-apis@w3.org
- Cc: Domenic Denicola <domenic@domenicdenicola.com>
Hi, When I wrote the getBattery() prose, I made it so that getBattery() would return a new promise every time it is called but it would always return the same BatteryManager when the promise is resolved. I realised that this requirement probably doesn't make much sense and we might want to spec getBattery() as returning always the same promise. In other words, navigator.getBattery() === navigator.getBattery(). The intent isn't really to get the equality but that way, we simplify the implementation because implementing this only require to keep track of that one promise. WDYT? -- Mounir
Received on Tuesday, 1 July 2014 10:04:19 UTC