@syncular/server 0.60.0 → 0.60.1

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.
@@ -927,9 +927,10 @@ export function serverIndexDdl(schema, existingIndexesByTable) {
927
927
  const drops = [];
928
928
  const creates = [];
929
929
  for (const table of schema.tables.values()) {
930
- const existing = existingIndexesByTable.get(table.name);
931
- if (existing === undefined)
932
- continue;
930
+ // Every table exists at the current version; a table the introspection
931
+ // reported no index for (Postgres lists none for a primary-key-only
932
+ // table) has none.
933
+ const existing = existingIndexesByTable.get(table.name) ?? new Map();
933
934
  const desired = desiredIndexes(table);
934
935
  for (const indexName of existing.keys()) {
935
936
  if (indexName.startsWith(SYNC_INDEX_PREFIX) &&
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@syncular/server",
3
- "version": "0.60.0",
3
+ "version": "0.60.1",
4
4
  "description": "Syncular server: handleSyncRequest + storage/auth interfaces for the sync protocol",
5
5
  "license": "Apache-2.0",
6
6
  "author": "Benjamin Kniffler",
@@ -68,7 +68,7 @@
68
68
  "verify:node": "cd ../.. && bun build ./packages/server/test/sqlite-runtime/verify-node.mjs --target=node --conditions=bun --outfile=./packages/server/.verify-node.built.mjs && node ./packages/server/.verify-node.built.mjs"
69
69
  },
70
70
  "dependencies": {
71
- "@syncular/core": "0.60.0"
71
+ "@syncular/core": "0.60.1"
72
72
  },
73
73
  "devDependencies": {
74
74
  "@electric-sql/pglite": "^0.5.4"
@@ -1165,8 +1165,10 @@ export function serverIndexDdl(
1165
1165
  const drops: string[] = [];
1166
1166
  const creates: string[] = [];
1167
1167
  for (const table of schema.tables.values()) {
1168
- const existing = existingIndexesByTable.get(table.name);
1169
- if (existing === undefined) continue;
1168
+ // Every table exists at the current version; a table the introspection
1169
+ // reported no index for (Postgres lists none for a primary-key-only
1170
+ // table) has none.
1171
+ const existing = existingIndexesByTable.get(table.name) ?? new Map();
1170
1172
  const desired = desiredIndexes(table);
1171
1173
  for (const indexName of existing.keys()) {
1172
1174
  if (