Ensure that failing to open the password dialog once won't permanently disable it (PR 15335 follow-up)

*Please note:* This situation should never happen in practice, but it nonetheless cannot hurt to fix this.

If the `PasswordPrompt.open` method would ever be called synchronously back-to-back *and* if opening of the dialog fails the first time, then the second invocation would remain pending indefinitely since we just clear out the capability.
This commit is contained in:
Jonas Jenwald 2023-07-30 08:34:41 +02:00
parent 7ae5a0fef7
commit 81dfa61777

View File

@ -74,7 +74,7 @@ class PasswordPrompt {
try {
await this.overlayManager.open(this.dialog);
} catch (ex) {
this.#activeCapability = null;
this.#activeCapability.resolve();
throw ex;
}