diff --git a/lib/keyserver-conn/recovery-utils.js b/lib/keyserver-conn/recovery-utils.js --- a/lib/keyserver-conn/recovery-utils.js +++ b/lib/keyserver-conn/recovery-utils.js @@ -180,7 +180,11 @@ source: RecoveryActionSource, sessionChange: ClientSessionChange, userStateBeforeRecovery: PreRequestUserState, + hasBeenCancelled: () => boolean, ) => { + if (hasBeenCancelled()) { + return; + } setNewSession( dispatch, sessionChange, @@ -234,6 +238,7 @@ source, sessionChange, userStateBeforeRecovery, + hasBeenCancelled, ); } } catch (e) { @@ -248,6 +253,7 @@ source, genericCookieInvalidation, userStateBeforeRecovery, + hasBeenCancelled, ); throw e; }