@middy/service-discovery 7.6.5 → 7.6.6

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.
Files changed (3) hide show
  1. package/README.md +1 -1
  2. package/index.js +3 -0
  3. package/package.json +5 -4
package/README.md CHANGED
@@ -22,7 +22,7 @@
22
22
  <a href="https://biomejs.dev"><img alt="Checked with Biome" src="https://img.shields.io/badge/Checked_with-Biome-60a5fa?style=flat&logo=biome"></a>
23
23
  <a href="https://conventionalcommits.org"><img alt="Conventional Commits" src="https://img.shields.io/badge/Conventional%20Commits-1.0.0-%23FE5196?logo=conventionalcommits&logoColor=white"></a>
24
24
  <a href="https://github.com/middyjs/middy/blob/main/package.json#L32">
25
- <img alt="code coverage" src="https://img.shields.io/badge/code%20coverage-95%25-brightgreen"></a>
25
+ <img alt="code coverage" src="https://img.shields.io/badge/code%20coverage-100%25-brightgreen"></a>
26
26
  <br/>
27
27
  </p>
28
28
  <p>You can read the documentation at: <a href="https://middy.js.org/docs/middlewares/service-discovery">https://middy.js.org/docs/middlewares/service-discovery</a></p>
package/index.js CHANGED
@@ -128,6 +128,9 @@ const serviceDiscoveryMiddleware = (opts = {}) => {
128
128
 
129
129
  if (contextSpec) {
130
130
  const pending = assignSetToContext(contextSpec, value, request);
131
+ // Stryker disable next-line ConditionalExpression: forcing the guard to
132
+ // `true` is equivalent; `await undefined` (warm/sync path) is a no-op and
133
+ // the cold path already returns a truthy promise.
131
134
  if (pending) await pending;
132
135
  }
133
136
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@middy/service-discovery",
3
- "version": "7.6.5",
3
+ "version": "7.6.6",
4
4
  "description": "Service Discovery (Cloud Map) instances middleware for the middy framework",
5
5
  "type": "module",
6
6
  "engines": {
@@ -29,7 +29,8 @@
29
29
  "test": "npm run test:unit && npm run test:fuzz",
30
30
  "test:unit": "node --test",
31
31
  "test:fuzz": "node --test index.fuzz.js",
32
- "test:perf": "node --test index.perf.js"
32
+ "test:perf": "node --test index.perf.js",
33
+ "test:mutation": "cd ../.. && MUTATE_PACKAGE=\"$(basename \"$OLDPWD\")\" stryker run"
33
34
  },
34
35
  "license": "MIT",
35
36
  "keywords": [
@@ -70,11 +71,11 @@
70
71
  }
71
72
  },
72
73
  "dependencies": {
73
- "@middy/util": "7.6.5"
74
+ "@middy/util": "7.6.6"
74
75
  },
75
76
  "devDependencies": {
76
77
  "@aws-sdk/client-servicediscovery": "^3.0.0",
77
- "@middy/core": "7.6.5",
78
+ "@middy/core": "7.6.6",
78
79
  "@types/aws-lambda": "^8.0.0",
79
80
  "@types/node": "^22.0.0",
80
81
  "aws-xray-sdk": "^3.3.3"