@powersync/web 0.0.0-dev-20250520135616 → 0.0.0-dev-20250526133243

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.
package/dist/index.umd.js CHANGED
@@ -38223,21 +38223,13 @@ class PowerSyncDatabase extends _powersync_common__WEBPACK_IMPORTED_MODULE_0__.A
38223
38223
  disconnect: options.disconnect ?? !this.resolvedFlags.enableMultiTabs
38224
38224
  });
38225
38225
  }
38226
- connect(connector, options) {
38227
- /**
38228
- * Using React strict mode might cause calls to connect to fire multiple times
38229
- * Connect is wrapped inside a lock in order to prevent race conditions internally between multiple
38230
- * connection attempts.
38231
- */
38232
- return this.runExclusive(() => {
38233
- this.options.logger?.debug('Attempting to connect to PowerSync instance');
38234
- return super.connect(connector, options);
38235
- });
38226
+ async connectExclusive(callback) {
38227
+ await this.runExclusive(callback);
38236
38228
  }
38237
38229
  generateBucketStorageAdapter() {
38238
38230
  return new _powersync_common__WEBPACK_IMPORTED_MODULE_0__.SqliteBucketStorage(this.database, _powersync_common__WEBPACK_IMPORTED_MODULE_0__.AbstractPowerSyncDatabase.transactionMutex);
38239
38231
  }
38240
- runExclusive(cb) {
38232
+ async runExclusive(cb) {
38241
38233
  if (this.resolvedFlags.ssrMode) {
38242
38234
  return PowerSyncDatabase.SHARED_MUTEX.runExclusive(cb);
38243
38235
  }