@powersync/common 1.57.0 → 1.57.2
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/bundle.cjs +11 -3
- package/dist/bundle.cjs.map +1 -1
- package/dist/bundle.mjs +11 -3
- package/dist/bundle.mjs.map +1 -1
- package/dist/bundle.node.cjs +11 -3
- package/dist/bundle.node.cjs.map +1 -1
- package/dist/bundle.node.mjs +11 -3
- package/dist/bundle.node.mjs.map +1 -1
- package/dist/index.d.cts +9 -9
- package/lib/client/sync/stream/AbstractRemote.d.ts +2 -2
- package/lib/client/sync/stream/AbstractRemote.js +3 -0
- package/lib/client/sync/stream/AbstractRemote.js.map +1 -1
- package/lib/client/triggers/TriggerManagerImpl.js +6 -1
- package/lib/client/triggers/TriggerManagerImpl.js.map +1 -1
- package/lib/db/crud/SyncStatus.d.ts +1 -1
- package/lib/db/crud/SyncStatus.js +1 -1
- package/lib/utils/Logger.d.ts +7 -7
- package/lib/utils/Logger.js.map +1 -1
- package/package.json +1 -1
- package/src/client/sync/stream/AbstractRemote.ts +5 -1
- package/src/client/triggers/TriggerManagerImpl.ts +6 -1
- package/src/db/crud/SyncStatus.ts +1 -1
- package/src/utils/Logger.ts +9 -1
package/dist/bundle.cjs
CHANGED
|
@@ -2110,7 +2110,7 @@ class SyncStatus {
|
|
|
2110
2110
|
});
|
|
2111
2111
|
}
|
|
2112
2112
|
/**
|
|
2113
|
-
* All sync streams currently being tracked in
|
|
2113
|
+
* All sync streams currently being tracked in the database.
|
|
2114
2114
|
*
|
|
2115
2115
|
* This returns null when the database is currently being opened and we don't have reliable information about all
|
|
2116
2116
|
* included streams yet.
|
|
@@ -10975,7 +10975,7 @@ function requireDist () {
|
|
|
10975
10975
|
|
|
10976
10976
|
var distExports = requireDist();
|
|
10977
10977
|
|
|
10978
|
-
var version = "1.57.
|
|
10978
|
+
var version = "1.57.2";
|
|
10979
10979
|
var PACKAGE = {
|
|
10980
10980
|
version: version};
|
|
10981
10981
|
|
|
@@ -11589,6 +11589,9 @@ class AbstractRemote {
|
|
|
11589
11589
|
if (!res.ok || !res.body) {
|
|
11590
11590
|
const text = await res.text();
|
|
11591
11591
|
this.logger.error(`Could not POST streaming to ${path} - ${res.status} - ${res.statusText}: ${text}`);
|
|
11592
|
+
if (res.status === 401) {
|
|
11593
|
+
this.invalidateCredentials();
|
|
11594
|
+
}
|
|
11592
11595
|
const error = new Error(`HTTP ${res.statusText}: ${text}`);
|
|
11593
11596
|
error.status = res.status;
|
|
11594
11597
|
throw error;
|
|
@@ -12726,7 +12729,12 @@ class TriggerManagerImpl {
|
|
|
12726
12729
|
// destination table consistent.
|
|
12727
12730
|
await this.db.writeTransaction(async (tx) => {
|
|
12728
12731
|
const callbackResult = await options.onChange({
|
|
12729
|
-
|
|
12732
|
+
execute: (query, params) => tx.execute(query, params),
|
|
12733
|
+
executeBatch: (query, params) => tx.executeBatch(query, params),
|
|
12734
|
+
executeRaw: (query, params) => tx.executeRaw(query, params),
|
|
12735
|
+
get: (query, params) => tx.get(query, params),
|
|
12736
|
+
getAll: (query, params) => tx.getAll(query, params),
|
|
12737
|
+
getOptional: (query, params) => tx.getOptional(query, params),
|
|
12730
12738
|
destinationTable: destination,
|
|
12731
12739
|
withDiff: async (query, params, options) => {
|
|
12732
12740
|
// Wrap the query to expose the destination table
|