Reject when `navigator.storage.estimate()` fails to calculate usage
Previously an error in retrieving buckets would return a usage of -1 (which is later converted to an unsigned integer, so is reported as 2^64). This changes QuotaManagerImpl logic to report an error which ultimately causes the promise to reject. This also changes the type of the rejection to be a TypeError instead of a DOMException to match the spec: https://storage.spec.whatwg.org/#dom-storagemanager-estimate Bug: 1451614 Change-Id: I2c23f5403e5410298e6279ea4982c1ad2b9b30a0 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4666778 Reviewed-by:Ayu Ishii <ayui@chromium.org> Reviewed-by:
Matthew Denton <mpdenton@chromium.org> Commit-Queue: Evan Stade <estade@chromium.org> Cr-Commit-Position: refs/heads/main@{#1168402}
Loading
Please register or sign in to comment