@graphql-box/cache-manager 5.4.7 → 5.4.11

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@graphql-box/cache-manager",
3
3
  "description": "The GraphQL Box cache manager module.",
4
- "version": "5.4.7",
4
+ "version": "5.4.11",
5
5
  "author": "Dylan Aubrey",
6
6
  "license": "MIT",
7
7
  "homepage": "https://github.com/badbatch/graphql-box",
@@ -36,21 +36,21 @@
36
36
  "cacheability": "^4.0.27",
37
37
  "core-js": "^3.39.0",
38
38
  "lodash-es": "^4.17.21",
39
- "@graphql-box/core": "5.4.6",
40
- "@graphql-box/helpers": "5.4.6"
39
+ "@graphql-box/helpers": "5.4.10",
40
+ "@graphql-box/core": "5.4.10"
41
41
  },
42
42
  "peerDependencies": {
43
43
  "@cachemap/core": "<6",
44
44
  "graphql": "<17"
45
45
  },
46
46
  "devDependencies": {
47
- "@cachemap/core": "^5.2.2",
47
+ "@cachemap/core": "^5.2.7",
48
48
  "@cachemap/map": "^5.0.8",
49
49
  "@jest/globals": "^29.3.1",
50
50
  "cts-types": "^0.0.8",
51
51
  "del-cli": "^6.0.0",
52
52
  "graphql": "^16.9.0",
53
- "@graphql-box/test-utils": "5.4.6"
53
+ "@graphql-box/test-utils": "5.4.10"
54
54
  },
55
55
  "keywords": [
56
56
  "client",
@@ -21,10 +21,7 @@ export const mergeResponseDataSets = (responseDataSets: RawResponseDataWithMaybe
21
21
  }
22
22
 
23
23
  if (paths) {
24
- if (!acc.paths) {
25
- acc.paths = [];
26
- }
27
-
24
+ acc.paths ??= [];
28
25
  acc.paths.push(...paths);
29
26
  }
30
27
 
package/src/main.ts CHANGED
@@ -368,6 +368,10 @@ export class CacheManager implements CacheManagerDef {
368
368
  return this._cacheResponse(requestData, undefined, rawResponseData, options, cacheManagerContext);
369
369
  }
370
370
 
371
+ get cacheTiersEnabled(): CacheTiersEnabled {
372
+ return this._cacheTiersEnabled;
373
+ }
374
+
371
375
  public async checkCacheEntry(
372
376
  cacheType: CacheTypes,
373
377
  hash: string,
package/src/types.ts CHANGED
@@ -175,6 +175,7 @@ export interface CacheManagerDef {
175
175
  options: RequestOptions,
176
176
  context: RequestContext,
177
177
  ): Promise<ResponseData>;
178
+ cacheTiersEnabled: CacheTiersEnabled;
178
179
  checkCacheEntry(
179
180
  cacheType: CacheTypes,
180
181
  hash: string,