@opengis/fastify-table 2.0.147 → 2.0.148
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/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../index.ts"],"names":[],"mappings":"AA4FA,iBAAS,MAAM,CAAC,OAAO,EAAE,GAAG,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../index.ts"],"names":[],"mappings":"AA4FA,iBAAS,MAAM,CAAC,OAAO,EAAE,GAAG,QA8K3B;;AACD,wBAA0B"}
|
package/dist/index.js
CHANGED
|
@@ -125,7 +125,7 @@ function plugin(fastify) {
|
|
|
125
125
|
timeWindow: config.rateLimit?.timeWindow || 60000,
|
|
126
126
|
hook: "preHandler",
|
|
127
127
|
global: true,
|
|
128
|
-
keyGenerator: (req) => `${req.ip}-${req.raw.url.split("?")[0]}`,
|
|
128
|
+
keyGenerator: (req) => `${req.user?.uid || req.ip}-${req.raw.url.split("?")[0]}`,
|
|
129
129
|
});
|
|
130
130
|
}
|
|
131
131
|
else {
|
|
@@ -256,7 +256,7 @@ export default async function suggest(req, reply) {
|
|
|
256
256
|
const where = [search, val, filter, meta.pk ? `${meta.pk} is not null` : null]
|
|
257
257
|
.filter(Boolean)
|
|
258
258
|
.join(" and ") || "true";
|
|
259
|
-
const sqlSuggest = `with c(id,text) as ( ${meta.original.replace(/{{parent}}/gi, parent)} where ${where} ${meta.original.includes("order by") ? "" : "order by 2"}) select * from c where ${filter} limit ${Math.min(query.limit || meta.limit || limit, limit)}`.replace(/{{uid}}/g, user?.uid || "0");
|
|
259
|
+
const sqlSuggest = `with c(id,text) as ( ${meta.original.replace(/{{parent}}/gi, parent)} where ${where} ${meta.original.toLowerCase().includes("order by") ? "" : "order by 2"}) select * from c where ${filter} limit ${Math.min(query.limit || meta.limit || limit, limit)}`.replace(/{{uid}}/g, user?.uid || "0");
|
|
260
260
|
if (query.sql && debugMode) {
|
|
261
261
|
return sqlSuggest;
|
|
262
262
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dependencies.d.ts","sourceRoot":"","sources":["../../../../../server/routes/util/controllers/dependencies.ts"],"names":[],"mappings":"AAQA,wBAA8B,iBAAiB,CAAC,GAAG,EAAE,GAAG,
|
|
1
|
+
{"version":3,"file":"dependencies.d.ts","sourceRoot":"","sources":["../../../../../server/routes/util/controllers/dependencies.ts"],"names":[],"mappings":"AAQA,wBAA8B,iBAAiB,CAAC,GAAG,EAAE,GAAG,eAcvD"}
|
|
@@ -9,5 +9,14 @@ export default async function dumpInstalledDeps(app) {
|
|
|
9
9
|
...json.dependencies,
|
|
10
10
|
...(json.devDependencies || {}),
|
|
11
11
|
...(json.peerDependencies || {}),
|
|
12
|
-
}).reduce((acc, curr) =>
|
|
12
|
+
}).reduce((acc, curr) => {
|
|
13
|
+
try {
|
|
14
|
+
Object.assign(acc, { [curr]: require(`${curr}/package.json`).version });
|
|
15
|
+
}
|
|
16
|
+
catch (err) {
|
|
17
|
+
Object.assign(acc, { [curr]: err.toString() });
|
|
18
|
+
// skip packages that does not explicidly provide access to package.json
|
|
19
|
+
}
|
|
20
|
+
return acc;
|
|
21
|
+
}, {});
|
|
13
22
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@opengis/fastify-table",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.148",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "core-plugins",
|
|
6
6
|
"keywords": [
|
|
@@ -15,7 +15,8 @@
|
|
|
15
15
|
"exports": {
|
|
16
16
|
".": "./dist/index.js",
|
|
17
17
|
"./index.js": "./dist/index.js",
|
|
18
|
-
"./utils.js": "./dist/utils.js"
|
|
18
|
+
"./utils.js": "./dist/utils.js",
|
|
19
|
+
"./package.json": "./package.json"
|
|
19
20
|
},
|
|
20
21
|
"files": [
|
|
21
22
|
"dist/*"
|