cross-tab-worker-databus 0.20.51 → 0.20.53

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.
@@ -1658,9 +1658,10 @@ var CrossTabDataBus = class {
1658
1658
  getStatus() {
1659
1659
  return this.status;
1660
1660
  }
1661
- /** Return a bounded snapshot of automatic transport recovery state. */
1661
+ /** Return the current automatic transport recovery state. `hasError` means a transport error is currently retained. */
1662
1662
  getRecoveryStats() {
1663
- return { attempt: this.recoveryAttempt, exhausted: this.recoveryExhausted, maxAttempts: this.recoveryMaxAttempts };
1663
+ const errorMessage = this.lastError instanceof Error ? this.lastError.message : this.lastError === null ? null : String(this.lastError);
1664
+ return { attempt: this.recoveryAttempt, exhausted: this.recoveryExhausted, maxAttempts: this.recoveryMaxAttempts, hasError: this.lastError !== null, errorMessage };
1664
1665
  }
1665
1666
  /** Snapshot of the cluster state (workers, routes, assignments).
1666
1667
  * For diagnostics only — the returned object is a shallow copy but