@lix-js/sdk 0.4.8 → 0.4.10
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/CHANGELOG.md +7 -0
- package/dist/change/apply-changes.test.js +3 -3
- package/dist/file-queue/file-queue-process.js +2 -2
- package/dist/file-queue/with-skip-file-queue.js +2 -2
- package/package.json +3 -2
- package/src/change/apply-changes.test.ts +2 -2
- package/src/file-queue/file-queue-process.ts +1 -1
- package/src/file-queue/with-skip-file-queue.ts +1 -1
package/CHANGELOG.md
ADDED
|
@@ -189,7 +189,7 @@ test("applies an insert change for a file if the file does not exist", async ()
|
|
|
189
189
|
await fileQueueSettled({ lix });
|
|
190
190
|
const changes1 = await lix.db
|
|
191
191
|
.selectFrom("change")
|
|
192
|
-
.orderBy("id desc")
|
|
192
|
+
.orderBy("id", "desc")
|
|
193
193
|
.selectAll()
|
|
194
194
|
.execute();
|
|
195
195
|
const snapshots1 = await lix.db.selectFrom("snapshot").selectAll().execute();
|
|
@@ -208,7 +208,7 @@ test("applies an insert change for a file if the file does not exist", async ()
|
|
|
208
208
|
await applyChanges({ lix: lix2, changes: changes1 });
|
|
209
209
|
const changes2 = await lix2.db
|
|
210
210
|
.selectFrom("change")
|
|
211
|
-
.orderBy("id desc")
|
|
211
|
+
.orderBy("id", "desc")
|
|
212
212
|
.selectAll()
|
|
213
213
|
.execute();
|
|
214
214
|
const file2 = await lix2.db
|
|
@@ -219,4 +219,4 @@ test("applies an insert change for a file if the file does not exist", async ()
|
|
|
219
219
|
expect(changes1).toEqual(changes2);
|
|
220
220
|
expect(file1).toEqual(file2);
|
|
221
221
|
});
|
|
222
|
-
//# sourceMappingURL=apply-changes.test.js.map
|
|
222
|
+
//# sourceMappingURL=apply-changes.test.js.map
|
|
@@ -33,7 +33,7 @@ export async function initFileQueueProcess(args) {
|
|
|
33
33
|
const entry = await args.lix.db
|
|
34
34
|
.selectFrom("file_queue")
|
|
35
35
|
.selectAll()
|
|
36
|
-
.orderBy("id asc")
|
|
36
|
+
.orderBy("id", "asc")
|
|
37
37
|
.limit(1)
|
|
38
38
|
.executeTakeFirst();
|
|
39
39
|
if (entry) {
|
|
@@ -88,4 +88,4 @@ export async function initFileQueueProcess(args) {
|
|
|
88
88
|
queueWorker();
|
|
89
89
|
return;
|
|
90
90
|
}
|
|
91
|
-
//# sourceMappingURL=file-queue-process.js.map
|
|
91
|
+
//# sourceMappingURL=file-queue-process.js.map
|
|
@@ -3,7 +3,7 @@ export async function withSkipFileQueue(db, operation) {
|
|
|
3
3
|
const queryEntryBefore = await trx
|
|
4
4
|
.selectFrom("file_queue")
|
|
5
5
|
.selectAll()
|
|
6
|
-
.orderBy("id desc")
|
|
6
|
+
.orderBy("id", "desc")
|
|
7
7
|
.executeTakeFirst();
|
|
8
8
|
// Perform the user's operation
|
|
9
9
|
const result = await operation(trx);
|
|
@@ -23,4 +23,4 @@ export async function withSkipFileQueue(db, operation) {
|
|
|
23
23
|
return db.transaction().execute(executeInTransaction);
|
|
24
24
|
}
|
|
25
25
|
}
|
|
26
|
-
//# sourceMappingURL=with-skip-file-queue.js.map
|
|
26
|
+
//# sourceMappingURL=with-skip-file-queue.js.map
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lix-js/sdk",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.4.
|
|
4
|
+
"version": "0.4.10",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"types": "./dist/index.d.ts",
|
|
7
7
|
"exports": {
|
|
@@ -9,6 +9,7 @@
|
|
|
9
9
|
},
|
|
10
10
|
"_filesComment": "Shipping src for better debugging experience",
|
|
11
11
|
"files": [
|
|
12
|
+
"CHANGELOG.md",
|
|
12
13
|
"dist",
|
|
13
14
|
"src"
|
|
14
15
|
],
|
|
@@ -22,7 +23,7 @@
|
|
|
22
23
|
"human-id": "^4.1.1",
|
|
23
24
|
"js-sha256": "^0.11.0",
|
|
24
25
|
"kysely": "^0.28.12",
|
|
25
|
-
"uuid": "^
|
|
26
|
+
"uuid": "^14.0.0",
|
|
26
27
|
"@lix-js/server-protocol-schema": "0.1.1",
|
|
27
28
|
"sqlite-wasm-kysely": "0.3.0"
|
|
28
29
|
},
|
|
@@ -228,7 +228,7 @@ test("applies an insert change for a file if the file does not exist", async ()
|
|
|
228
228
|
|
|
229
229
|
const changes1 = await lix.db
|
|
230
230
|
.selectFrom("change")
|
|
231
|
-
.orderBy("id desc")
|
|
231
|
+
.orderBy("id", "desc")
|
|
232
232
|
.selectAll()
|
|
233
233
|
.execute();
|
|
234
234
|
|
|
@@ -253,7 +253,7 @@ test("applies an insert change for a file if the file does not exist", async ()
|
|
|
253
253
|
|
|
254
254
|
const changes2 = await lix2.db
|
|
255
255
|
.selectFrom("change")
|
|
256
|
-
.orderBy("id desc")
|
|
256
|
+
.orderBy("id", "desc")
|
|
257
257
|
.selectAll()
|
|
258
258
|
.execute();
|
|
259
259
|
|