@exabugs/dynamodb-client 1.4.7 → 1.4.8
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/server/handler.cjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
// @exabugs/dynamodb-client v1.4.
|
|
2
|
-
// Built: 2026-04-
|
|
1
|
+
// @exabugs/dynamodb-client v1.4.8
|
|
2
|
+
// Built: 2026-04-05T11:02:55.391Z
|
|
3
3
|
"use strict";
|
|
4
4
|
var __create = Object.create;
|
|
5
5
|
var __defProp = Object.defineProperty;
|
|
@@ -30902,7 +30902,8 @@ function selectFilterFirstCandidate(parsedFilters, sortField, schema, perPage) {
|
|
|
30902
30902
|
if (!cardinality) {
|
|
30903
30903
|
return eqFilters[0];
|
|
30904
30904
|
}
|
|
30905
|
-
const
|
|
30905
|
+
const threshold = perPage / 2;
|
|
30906
|
+
const scored = eqFilters.map((f4) => ({ f: f4, score: cardinality[f4.parsed.field] ?? 0 })).filter(({ score }) => score > threshold).sort((a4, b4) => b4.score - a4.score);
|
|
30906
30907
|
return scored[0]?.f;
|
|
30907
30908
|
}
|
|
30908
30909
|
function sortInMemory(items, sort) {
|
|
@@ -34400,7 +34401,7 @@ async function handler(event) {
|
|
|
34400
34401
|
return createCorsResponse(HTTP_STATUS.OK);
|
|
34401
34402
|
}
|
|
34402
34403
|
if (event.requestContext.http.method === "GET" && event.requestContext.http.path === "/version") {
|
|
34403
|
-
const version = "1.4.
|
|
34404
|
+
const version = "1.4.8";
|
|
34404
34405
|
return createSuccessResponse({ version, timestamp: (/* @__PURE__ */ new Date()).toISOString() }, requestId);
|
|
34405
34406
|
}
|
|
34406
34407
|
if (event.requestContext.http.method !== "POST") {
|