@based/db 0.2.15 → 0.2.17

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.
Binary file
Binary file
@@ -2,7 +2,7 @@ import { TEXT } from '@based/schema/def';
2
2
  import { writeObject } from '../props/object.js';
3
3
  import { reserve } from '../resize.js';
4
4
  import { FULL_CURSOR_SIZE, PROP_CURSOR_SIZE, writeMainCursor, writeTypeCursor, } from '../cursor.js';
5
- import { getByPath, writeUint16 } from '@based/utils';
5
+ import { getByPath, writeUint16, writeUint32 } from '@based/utils';
6
6
  import { writeMainValue } from '../props/main.js';
7
7
  import { Tmp } from '../Tmp.js';
8
8
  import { schedule } from '../drain.js';
@@ -76,7 +76,7 @@ const writeSortableText = (ctx) => {
76
76
  reserve(ctx, 3);
77
77
  writeU8(ctx, ADD_EMPTY_SORT_TEXT);
78
78
  const index = ctx.index;
79
- ctx.index += 2;
79
+ ctx.index += 4;
80
80
  const start = ctx.index;
81
81
  const amount = ctx.schema.localeSize + 1;
82
82
  const len = amount * ctx.schema.separateTextSort.props.length;
@@ -98,7 +98,7 @@ const writeSortableText = (ctx) => {
98
98
  writeU8(ctx, lang);
99
99
  }
100
100
  }
101
- writeUint16(ctx.array, ctx.index - start, index);
101
+ writeUint32(ctx.array, ctx.index - start, index);
102
102
  if (ctx.sortText) {
103
103
  buf.set(ctx.schema.separateTextSort.buffer, 0);
104
104
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@based/db",
3
- "version": "0.2.15",
3
+ "version": "0.2.17",
4
4
  "type": "module",
5
5
  "main": "./dist/src/index.js",
6
6
  "scripts": {