@secrecy/lib 1.9.0 → 1.9.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -21,8 +21,12 @@ export class BaseClient {
21
21
  this.sessionId = session;
22
22
  this.client = BaseClient.getBaseClient(session, async () => {
23
23
  await onAccessDenied?.();
24
- await this.logout();
25
- location.reload();
24
+ try {
25
+ await this.logout();
26
+ }
27
+ finally {
28
+ location.reload();
29
+ }
26
30
  });
27
31
  }
28
32
  async logout(sessionId) {
@@ -27,7 +27,12 @@ export class SecrecyClient extends BaseClient {
27
27
  user;
28
28
  constructor(uaSession, uaKeys, uaJwt) {
29
29
  super(uaSession, async () => {
30
- await this.logout();
30
+ try {
31
+ await this.logout();
32
+ }
33
+ catch {
34
+ // ignore
35
+ }
31
36
  });
32
37
  this.#keys = uaKeys;
33
38
  this.care = new SecrecyCareClient(this, this.#keys, this.client);
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@secrecy/lib",
3
3
  "author": "Anonymize <anonymize@gmail.com>",
4
4
  "description": "Anonymize Secrecy Library",
5
- "version": "1.9.0",
5
+ "version": "1.9.1",
6
6
  "repository": {
7
7
  "type": "git",
8
8
  "url": "https://github.com/anonymize-org/lib.git"