@palbase/backend 25.0.3 → 25.0.4
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/bin/palbase-backend.cjs +19 -3
- package/dist/bin/palbase-backend.cjs.map +1 -1
- package/dist/bin/palbase-backend.js +3 -3
- package/dist/{chunk-WH2EV2LT.js → chunk-AILPKEK5.js} +5 -5
- package/dist/chunk-AILPKEK5.js.map +1 -0
- package/dist/{chunk-P2Q27SGP.js → chunk-CJSKYY76.js} +182 -2
- package/dist/chunk-CJSKYY76.js.map +1 -0
- package/dist/{chunk-XJ2RSHEU.js → chunk-CRQKCRGF.js} +16 -2
- package/dist/chunk-CRQKCRGF.js.map +1 -0
- package/dist/{chunk-7JSEN7UR.js → chunk-G4R6BTLV.js} +3 -182
- package/dist/chunk-G4R6BTLV.js.map +1 -0
- package/dist/db/index.cjs +1 -1
- package/dist/db/index.cjs.map +1 -1
- package/dist/db/index.js +2 -2
- package/dist/engine/index.cjs +19 -3
- package/dist/engine/index.cjs.map +1 -1
- package/dist/engine/index.js +3 -3
- package/dist/index.cjs +15 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +6 -6
- package/package.json +1 -1
- package/dist/chunk-7JSEN7UR.js.map +0 -1
- package/dist/chunk-P2Q27SGP.js.map +0 -1
- package/dist/chunk-WH2EV2LT.js.map +0 -1
- package/dist/chunk-XJ2RSHEU.js.map +0 -1
|
@@ -492,6 +492,20 @@ function makeTableProxy(ops, prefix) {
|
|
|
492
492
|
findById: (id) => ops().findById(name, id),
|
|
493
493
|
findMany: (query, opts) => ops().findMany(name, query, opts),
|
|
494
494
|
upsert: (data, opts) => ops().upsert(name, data, opts),
|
|
495
|
+
// THREE VERBS THE TYPE PROMISED AND THIS PROXY DID NOT EMIT.
|
|
496
|
+
//
|
|
497
|
+
// `EnvTypedTableBase` declares `updateMany`, `deleteMany` and `count`
|
|
498
|
+
// (typed-db.ts) and the ops layer implements all three — only this
|
|
499
|
+
// proxy, which is what a handler actually touches, left them out. So
|
|
500
|
+
// the type said the verb exists, autocomplete offered it, and the call
|
|
501
|
+
// answered `undefined is not a function`.
|
|
502
|
+
//
|
|
503
|
+
// Older than this run, but the run rewrote this proxy for
|
|
504
|
+
// `Database.schema(name).tables.*` and would have carried the gap onto
|
|
505
|
+
// the new surface too.
|
|
506
|
+
updateMany: (where, set) => ops().updateMany(name, where, set),
|
|
507
|
+
deleteMany: (where) => ops().deleteMany(name, where),
|
|
508
|
+
count: (where) => ops().count(name, where),
|
|
495
509
|
search: (params) => ops().search(name, params),
|
|
496
510
|
similar: (id, params) => ops().similar(name, id, params),
|
|
497
511
|
recommend: (params) => ops().recommend(name, params),
|
|
@@ -1093,6 +1107,11 @@ function assertUsableWriteValues(caller, table, cols, data) {
|
|
|
1093
1107
|
}
|
|
1094
1108
|
}
|
|
1095
1109
|
|
|
1110
|
+
// src/db/schema-json.ts
|
|
1111
|
+
function qualifiedTableKey(schemaName, tableName) {
|
|
1112
|
+
return schemaName === "" || schemaName === "public" ? tableName : `${schemaName}.${tableName}`;
|
|
1113
|
+
}
|
|
1114
|
+
|
|
1096
1115
|
// src/engine/db.ts
|
|
1097
1116
|
function quoteIdent(name) {
|
|
1098
1117
|
return `"${name.replace(/"/g, '""')}"`;
|
|
@@ -2255,9 +2274,6 @@ function setSchema(schemas) {
|
|
|
2255
2274
|
}
|
|
2256
2275
|
currentSchema = { tables };
|
|
2257
2276
|
}
|
|
2258
|
-
function qualifiedTableKey(schema, table) {
|
|
2259
|
-
return schema === "" || schema === "public" ? table : `${schema}.${table}`;
|
|
2260
|
-
}
|
|
2261
2277
|
function withTables(ops, schema = currentSchema) {
|
|
2262
2278
|
const bind = (key) => ({
|
|
2263
2279
|
insert: (data) => ops.insert(key, data),
|