Commit e99ee270 authored by Raphael Kubo da Costa's avatar Raphael Kubo da Costa Committed by Commit Bot

wake lock: Slightly adjust the message set with an AbortError exception

Switch from "Wake Lock is being released" to "Wake Lock released" to make it
less confusing. The former can sound like the lock is still being released
by the time the message can be inspected, while the latter indicates this is
an operation that has been completed and cannot be reversed.

Bug: 257511
Change-Id: I8b0d3b749d404031d2e23da4050988c733be6689
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1643471
Auto-Submit: Raphael Kubo da Costa <raphael.kubo.da.costa@intel.com>
Reviewed-by: default avatarReilly Grant <reillyg@chromium.org>
Commit-Queue: Raphael Kubo da Costa <raphael.kubo.da.costa@intel.com>
Cr-Commit-Position: refs/heads/master@{#666031}
parent 0909cc52
...@@ -66,7 +66,7 @@ void WakeLockStateRecord::ReleaseWakeLock(ActiveLocksType::iterator iterator) { ...@@ -66,7 +66,7 @@ void WakeLockStateRecord::ReleaseWakeLock(ActiveLocksType::iterator iterator) {
// 2. Reject lockPromise with an "AbortError" DOMException. // 2. Reject lockPromise with an "AbortError" DOMException.
ScriptPromiseResolver* resolver = *iterator; ScriptPromiseResolver* resolver = *iterator;
resolver->Reject(MakeGarbageCollected<DOMException>( resolver->Reject(MakeGarbageCollected<DOMException>(
DOMExceptionCode::kAbortError, "Wake Lock is being released")); DOMExceptionCode::kAbortError, "Wake Lock released"));
// 3. Let document be the responsible document of the current settings object. // 3. Let document be the responsible document of the current settings object.
// 4. Let record be the platform wake lock's state record associated with // 4. Let record be the platform wake lock's state record associated with
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment