dexie-cloud-addon 4.0.2 → 4.0.3

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.
@@ -8,7 +8,7 @@
8
8
  *
9
9
  * ==========================================================================
10
10
  *
11
- * Version 4.0.2, Wed Apr 10 2024
11
+ * Version 4.0.3, Sat Apr 13 2024
12
12
  *
13
13
  * https://dexie.org
14
14
  *
@@ -2537,6 +2537,9 @@ function refreshAccessToken(url, login) {
2537
2537
  if (response.userValidUntil != null) {
2538
2538
  login.license.validUntil = new Date(response.userValidUntil);
2539
2539
  }
2540
+ if (response.data) {
2541
+ login.data = response.data;
2542
+ }
2540
2543
  return login;
2541
2544
  });
2542
2545
  }
@@ -2591,6 +2594,7 @@ function userAuthenticate(context, fetchToken, userInteraction, hints) {
2591
2594
  type: response2.userType,
2592
2595
  status: response2.claims.license || 'ok',
2593
2596
  };
2597
+ context.data = response2.data;
2594
2598
  if (response2.evalDaysLeft != null) {
2595
2599
  context.license.evalDaysLeft = response2.evalDaysLeft;
2596
2600
  }
@@ -3919,6 +3923,7 @@ function MessagesFromServerConsumer(db) {
3919
3923
  accessTokenExpiration: refreshedLogin.accessTokenExpiration,
3920
3924
  claims: refreshedLogin.claims,
3921
3925
  license: refreshedLogin.license,
3926
+ data: refreshedLogin.data,
3922
3927
  });
3923
3928
  // Updating $logins will trigger emission of db.cloud.currentUser observable, which
3924
3929
  // in turn will lead to that connectWebSocket.ts will reconnect the socket with the
@@ -5467,6 +5472,7 @@ function connectWebSocket(db) {
5467
5472
  accessTokenExpiration: refreshedLogin.accessTokenExpiration,
5468
5473
  claims: refreshedLogin.claims,
5469
5474
  license: refreshedLogin.license,
5475
+ data: refreshedLogin.data
5470
5476
  });
5471
5477
  })), switchMap(() => createObservable()));
5472
5478
  }
@@ -6293,7 +6299,7 @@ function dexieCloud(dexie) {
6293
6299
  const syncComplete = new Subject();
6294
6300
  dexie.cloud = {
6295
6301
  // @ts-ignore
6296
- version: "4.0.2",
6302
+ version: "4.0.3",
6297
6303
  options: Object.assign({}, DEFAULT_OPTIONS),
6298
6304
  schema: null,
6299
6305
  get currentUserId() {
@@ -6570,7 +6576,7 @@ function dexieCloud(dexie) {
6570
6576
  }
6571
6577
  }
6572
6578
  // @ts-ignore
6573
- dexieCloud.version = "4.0.2";
6579
+ dexieCloud.version = "4.0.3";
6574
6580
  Dexie.Cloud = dexieCloud;
6575
6581
 
6576
6582
  // In case the SW lives for a while, let it reuse already opened connections: