@unicitylabs/sphere-sdk 0.9.1-dev.8 → 0.9.1-dev.9

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.
@@ -1500,7 +1500,10 @@ declare class WalletApiTokenStorageProvider implements TokenStorageProvider<TxfS
1500
1500
  private readonly view;
1501
1501
  /**
1502
1502
  * Empty-import protection (§5.1): no removal is ever pushed before this
1503
- * flips on the first successful inventory load.
1503
+ * flips on the first successful inventory load. Doubles as the per-session
1504
+ * first-sync flag (#521): while false, `syncInventory` full-pulls even with
1505
+ * a warm persisted cursor — the view Map is process-lifetime, so a reloaded
1506
+ * instance (tab refresh) must rebuild it before deltas can resume.
1504
1507
  */
1505
1508
  private hadSuccessfulLoad;
1506
1509
  constructor(config: WalletApiTokenStorageConfig);
@@ -1500,7 +1500,10 @@ declare class WalletApiTokenStorageProvider implements TokenStorageProvider<TxfS
1500
1500
  private readonly view;
1501
1501
  /**
1502
1502
  * Empty-import protection (§5.1): no removal is ever pushed before this
1503
- * flips on the first successful inventory load.
1503
+ * flips on the first successful inventory load. Doubles as the per-session
1504
+ * first-sync flag (#521): while false, `syncInventory` full-pulls even with
1505
+ * a warm persisted cursor — the view Map is process-lifetime, so a reloaded
1506
+ * instance (tab refresh) must rebuild it before deltas can resume.
1504
1507
  */
1505
1508
  private hadSuccessfulLoad;
1506
1509
  constructor(config: WalletApiTokenStorageConfig);
@@ -1475,7 +1475,10 @@ var WalletApiTokenStorageProvider = class {
1475
1475
  view = /* @__PURE__ */ new Map();
1476
1476
  /**
1477
1477
  * Empty-import protection (§5.1): no removal is ever pushed before this
1478
- * flips on the first successful inventory load.
1478
+ * flips on the first successful inventory load. Doubles as the per-session
1479
+ * first-sync flag (#521): while false, `syncInventory` full-pulls even with
1480
+ * a warm persisted cursor — the view Map is process-lifetime, so a reloaded
1481
+ * instance (tab refresh) must rebuild it before deltas can resume.
1479
1482
  */
1480
1483
  hadSuccessfulLoad = false;
1481
1484
  constructor(config) {
@@ -1596,7 +1599,7 @@ var WalletApiTokenStorageProvider = class {
1596
1599
  /** Converge the local view with the server (delta when possible). */
1597
1600
  async syncInventory() {
1598
1601
  const cursor = await this.readCursor();
1599
- if (cursor === null) {
1602
+ if (cursor === null || !this.hadSuccessfulLoad) {
1600
1603
  await this.fullPull();
1601
1604
  } else if (await this.deltaLoop(cursor)) {
1602
1605
  await this.handleSyncEpochChange();