@uniformdev/redirect 19.20.1-alpha.32 → 19.22.0
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.esm.js +3 -4
- package/dist/index.js +3 -4
- package/dist/index.mjs +3 -4
- package/package.json +3 -3
package/dist/index.esm.js
CHANGED
|
@@ -233,7 +233,7 @@ var _RedirectClient = class extends ApiClient {
|
|
|
233
233
|
this.getRedirectTrie = async (options) => {
|
|
234
234
|
var _a, _b;
|
|
235
235
|
const { projectId } = this.options;
|
|
236
|
-
const key =
|
|
236
|
+
const key = projectId;
|
|
237
237
|
const cachePromise = (options == null ? void 0 : options.bypassDataCache) ? void 0 : (_a = this.options.dataCache) == null ? void 0 : _a.get(key);
|
|
238
238
|
if (cachePromise) {
|
|
239
239
|
const result = await cachePromise;
|
|
@@ -288,7 +288,6 @@ var _RedirectClient = class extends ApiClient {
|
|
|
288
288
|
projectId: this.options.projectId
|
|
289
289
|
})
|
|
290
290
|
});
|
|
291
|
-
this.resetRedirectTrieDataCache();
|
|
292
291
|
return result.id;
|
|
293
292
|
};
|
|
294
293
|
this.deleteRedirect = async (id) => {
|
|
@@ -310,9 +309,9 @@ var _RedirectClient = class extends ApiClient {
|
|
|
310
309
|
return _RedirectClient.processHops(url, trie, false, options);
|
|
311
310
|
};
|
|
312
311
|
if (options.dataCache && options.dataCache.options.prePopulate) {
|
|
313
|
-
if (!options.dataCache.get(
|
|
312
|
+
if (!options.dataCache.get(options.projectId)) {
|
|
314
313
|
options.dataCache.set(
|
|
315
|
-
|
|
314
|
+
options.projectId,
|
|
316
315
|
this.getRedirectTrie(),
|
|
317
316
|
() => this.getRedirectTrie({ bypassDataCache: true })
|
|
318
317
|
);
|
package/dist/index.js
CHANGED
|
@@ -559,7 +559,7 @@ var _RedirectClient = class extends import_api.ApiClient {
|
|
|
559
559
|
this.getRedirectTrie = async (options) => {
|
|
560
560
|
var _a, _b;
|
|
561
561
|
const { projectId } = this.options;
|
|
562
|
-
const key =
|
|
562
|
+
const key = projectId;
|
|
563
563
|
const cachePromise = (options == null ? void 0 : options.bypassDataCache) ? void 0 : (_a = this.options.dataCache) == null ? void 0 : _a.get(key);
|
|
564
564
|
if (cachePromise) {
|
|
565
565
|
const result = await cachePromise;
|
|
@@ -614,7 +614,6 @@ var _RedirectClient = class extends import_api.ApiClient {
|
|
|
614
614
|
projectId: this.options.projectId
|
|
615
615
|
})
|
|
616
616
|
});
|
|
617
|
-
this.resetRedirectTrieDataCache();
|
|
618
617
|
return result.id;
|
|
619
618
|
};
|
|
620
619
|
this.deleteRedirect = async (id) => {
|
|
@@ -636,9 +635,9 @@ var _RedirectClient = class extends import_api.ApiClient {
|
|
|
636
635
|
return _RedirectClient.processHops(url, trie, false, options);
|
|
637
636
|
};
|
|
638
637
|
if (options.dataCache && options.dataCache.options.prePopulate) {
|
|
639
|
-
if (!options.dataCache.get(
|
|
638
|
+
if (!options.dataCache.get(options.projectId)) {
|
|
640
639
|
options.dataCache.set(
|
|
641
|
-
|
|
640
|
+
options.projectId,
|
|
642
641
|
this.getRedirectTrie(),
|
|
643
642
|
() => this.getRedirectTrie({ bypassDataCache: true })
|
|
644
643
|
);
|
package/dist/index.mjs
CHANGED
|
@@ -233,7 +233,7 @@ var _RedirectClient = class extends ApiClient {
|
|
|
233
233
|
this.getRedirectTrie = async (options) => {
|
|
234
234
|
var _a, _b;
|
|
235
235
|
const { projectId } = this.options;
|
|
236
|
-
const key =
|
|
236
|
+
const key = projectId;
|
|
237
237
|
const cachePromise = (options == null ? void 0 : options.bypassDataCache) ? void 0 : (_a = this.options.dataCache) == null ? void 0 : _a.get(key);
|
|
238
238
|
if (cachePromise) {
|
|
239
239
|
const result = await cachePromise;
|
|
@@ -288,7 +288,6 @@ var _RedirectClient = class extends ApiClient {
|
|
|
288
288
|
projectId: this.options.projectId
|
|
289
289
|
})
|
|
290
290
|
});
|
|
291
|
-
this.resetRedirectTrieDataCache();
|
|
292
291
|
return result.id;
|
|
293
292
|
};
|
|
294
293
|
this.deleteRedirect = async (id) => {
|
|
@@ -310,9 +309,9 @@ var _RedirectClient = class extends ApiClient {
|
|
|
310
309
|
return _RedirectClient.processHops(url, trie, false, options);
|
|
311
310
|
};
|
|
312
311
|
if (options.dataCache && options.dataCache.options.prePopulate) {
|
|
313
|
-
if (!options.dataCache.get(
|
|
312
|
+
if (!options.dataCache.get(options.projectId)) {
|
|
314
313
|
options.dataCache.set(
|
|
315
|
-
|
|
314
|
+
options.projectId,
|
|
316
315
|
this.getRedirectTrie(),
|
|
317
316
|
() => this.getRedirectTrie({ bypassDataCache: true })
|
|
318
317
|
);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@uniformdev/redirect",
|
|
3
|
-
"version": "19.
|
|
3
|
+
"version": "19.22.0",
|
|
4
4
|
"description": "Uniform redirect client",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE.txt",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -32,12 +32,12 @@
|
|
|
32
32
|
"/dist"
|
|
33
33
|
],
|
|
34
34
|
"dependencies": {
|
|
35
|
-
"@uniformdev/context": "19.
|
|
35
|
+
"@uniformdev/context": "19.22.0",
|
|
36
36
|
"p-limit": "^3.1.0",
|
|
37
37
|
"rfdc": "^1.3.0"
|
|
38
38
|
},
|
|
39
39
|
"publishConfig": {
|
|
40
40
|
"access": "public"
|
|
41
41
|
},
|
|
42
|
-
"gitHead": "
|
|
42
|
+
"gitHead": "f3b826c15f64a8abc5bd7ca08c0539bd85684cf9"
|
|
43
43
|
}
|