oas 17.1.5 → 17.1.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.
package/CHANGELOG.md CHANGED
@@ -1,3 +1,9 @@
1
+ ## <small>17.1.6 (2021-11-29)</small>
2
+
3
+ * fix: exposing response header descriptions in response json schema (#541) ([d6abf9e](https://github.com/readmeio/oas/commit/d6abf9e)), closes [#541](https://github.com/readmeio/oas/issues/541)
4
+
5
+
6
+
1
7
  ## <small>17.1.5 (2021-11-22)</small>
2
8
 
3
9
  * fix: don't fail to dereference if the api definition is nullish ([e1e33a6](https://github.com/readmeio/oas/commit/e1e33a6))
@@ -22,6 +22,9 @@ function buildHeadersSchema(response) {
22
22
  // This means they can have content instead of schema.
23
23
  // We should probably support that in the future
24
24
  headersSchema.properties[key] = toJSONSchema(headers[key].schema);
25
+ if (headers[key].description) {
26
+ headersSchema.properties[key].description = headers[key].description;
27
+ }
25
28
  }
26
29
  });
27
30
  var headersWrapper = {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "oas",
3
- "version": "17.1.5",
3
+ "version": "17.1.6",
4
4
  "description": "Working with OpenAPI definitions is hard. This makes it easier.",
5
5
  "license": "MIT",
6
6
  "author": "ReadMe <support@readme.io> (https://readme.com)",
@@ -25,6 +25,9 @@ function buildHeadersSchema(response) {
25
25
  // This means they can have content instead of schema.
26
26
  // We should probably support that in the future
27
27
  headersSchema.properties[key] = toJSONSchema(headers[key].schema);
28
+ if (headers[key].description) {
29
+ headersSchema.properties[key].description = headers[key].description;
30
+ }
28
31
  }
29
32
  });
30
33