@static-suite/static-suite-data-server 0.0.29 → 0.0.30
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/http/routes/cache.js +2 -2
- package/dist/http/routes/indexUUID.js +1 -1
- package/dist/http/routes/task.js +1 -1
- package/dist/lib/tsdoc-metadata.json +1 -1
- package/package.json +1 -1
- package/src/http/routes/cache.ts +2 -2
- package/src/http/routes/indexUUID.ts +1 -1
- package/src/http/routes/task.ts +1 -1
|
@@ -10,8 +10,8 @@ exports.cacheIndex = cacheIndex;
|
|
|
10
10
|
const cacheClear = (req, res) => {
|
|
11
11
|
const { cacheBinId } = req.params;
|
|
12
12
|
let done = false;
|
|
13
|
-
if (cache_1.cache.has(cacheBinId)) {
|
|
14
|
-
cache_1.cache.bin(cacheBinId).clear();
|
|
13
|
+
if (cache_1.cache.has(String(cacheBinId))) {
|
|
14
|
+
cache_1.cache.bin(String(cacheBinId)).clear();
|
|
15
15
|
done = true;
|
|
16
16
|
}
|
|
17
17
|
res.render('cacheClear', { cacheBinId, done });
|
|
@@ -9,7 +9,7 @@ const indexUUID = (req, res) => {
|
|
|
9
9
|
dataDir_1.dataDirManager.update();
|
|
10
10
|
const { langcode, uuid } = req.params;
|
|
11
11
|
const storeFile = uuid
|
|
12
|
-
? store_1.store.index.uuid.get(langcode)?.get(uuid)
|
|
12
|
+
? store_1.store.index.uuid.get(String(langcode))?.get(String(uuid))
|
|
13
13
|
: undefined;
|
|
14
14
|
if (storeFile === undefined) {
|
|
15
15
|
res.status(404);
|
package/dist/http/routes/task.js
CHANGED
|
@@ -14,7 +14,7 @@ const runTask = (req, res) => {
|
|
|
14
14
|
dataDir_1.dataDirManager.update();
|
|
15
15
|
const args = req.query;
|
|
16
16
|
const { taskId } = req.params;
|
|
17
|
-
const response = task_1.taskRunner.run(taskId, args);
|
|
17
|
+
const response = task_1.taskRunner.run(String(taskId), args);
|
|
18
18
|
res.status('metadata' in response && response.metadata.httpStatus
|
|
19
19
|
? response.metadata.httpStatus
|
|
20
20
|
: 200);
|
package/package.json
CHANGED
package/src/http/routes/cache.ts
CHANGED
|
@@ -9,8 +9,8 @@ export const cacheIndex = (req: Request, res: Response): void => {
|
|
|
9
9
|
export const cacheClear = (req: Request, res: Response): void => {
|
|
10
10
|
const { cacheBinId } = req.params;
|
|
11
11
|
let done = false;
|
|
12
|
-
if (cache.has(cacheBinId)) {
|
|
13
|
-
cache.bin(cacheBinId).clear();
|
|
12
|
+
if (cache.has(String(cacheBinId))) {
|
|
13
|
+
cache.bin(String(cacheBinId)).clear();
|
|
14
14
|
done = true;
|
|
15
15
|
}
|
|
16
16
|
res.render('cacheClear', { cacheBinId, done });
|
|
@@ -9,7 +9,7 @@ const indexUUID = (req: Request, res: Response): void => {
|
|
|
9
9
|
const { langcode, uuid } = req.params;
|
|
10
10
|
|
|
11
11
|
const storeFile = uuid
|
|
12
|
-
? store.index.uuid.get(langcode)?.get(uuid)
|
|
12
|
+
? store.index.uuid.get(String(langcode))?.get(String(uuid))
|
|
13
13
|
: undefined;
|
|
14
14
|
if (storeFile === undefined) {
|
|
15
15
|
res.status(404);
|
package/src/http/routes/task.ts
CHANGED
|
@@ -18,7 +18,7 @@ const runTask = (req: Request, res: Response): void => {
|
|
|
18
18
|
const args: any = req.query;
|
|
19
19
|
const { taskId } = req.params;
|
|
20
20
|
const response: TaskSuccessfulResponse | TaskErrorResponse = taskRunner.run(
|
|
21
|
-
taskId,
|
|
21
|
+
String(taskId),
|
|
22
22
|
args,
|
|
23
23
|
);
|
|
24
24
|
res.status(
|