@jwn-js/common 2.0.38 → 2.0.39

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/index.js CHANGED
@@ -1169,16 +1169,15 @@ class Web {
1169
1169
  if (["get", "head"].includes(this.contextWeb.method) && this.contextWeb?.stack?.memcached instanceof Memcached) {
1170
1170
  const memcached = this.contextWeb.stack.memcached;
1171
1171
  if (memcached.isConnectedServers()) {
1172
- memcached.getPage(this.memcachedKey).then((cache) => {
1173
- if (cache) {
1174
- const { data, headers } = cache;
1175
- this.success({
1176
- body: data.toString(),
1177
- headers,
1178
- statusCode: 200
1179
- });
1180
- }
1181
- });
1172
+ const cache = await memcached.getPage(this.memcachedKey);
1173
+ if (cache) {
1174
+ const { data, headers } = cache;
1175
+ this.success({
1176
+ body: data.toString(),
1177
+ headers,
1178
+ statusCode: 200
1179
+ });
1180
+ }
1182
1181
  }
1183
1182
  }
1184
1183
  request.controller = request.controller || this.defaultControllerSubaction.controller;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@jwn-js/common",
3
3
  "private": false,
4
- "version": "2.0.38",
4
+ "version": "2.0.39",
5
5
  "description": "@jwn-js/common package",
6
6
  "main": "./index.js",
7
7
  "types": "./index.d.ts",