Skip to content

Commit 07c786a

Browse files
Merge pull request #56 from codefresh-io/CR-18399-headers
CR-18399 -- headers
2 parents 3a0bd24 + c9f47dd commit 07c786a

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

lib/redoc/index.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ const defaults = require('../../defaults');
1111

1212
module.exports = {
1313
handleRedocIndex: (app, specPath, redocPath, middleware = []) => {
14-
app.get(redocPath, ...middleware, (req, res) => res.send(html.replace(SPEC_PATTERN, specPath)));
14+
app.get(redocPath, ...middleware, (req, res) => res.header('Content-Type', 'text/html').send(html.replace(SPEC_PATTERN, specPath)));
1515
},
16-
handleRedocScript: app => app.get(defaults.REDOC_STATIC_PATH, (req, res) => res.send(js)),
16+
handleRedocScript: app => app.get(defaults.REDOC_STATIC_PATH, (req, res) => res.header('Content-Type', 'text/javascript').send(js)),
1717
};

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@codefresh-io/cf-openapi",
3-
"version": "0.7.14",
3+
"version": "0.7.15",
44
"scripts": {
55
"test": "jest --runInBand",
66
"eslint": "eslint lib/**"

0 commit comments

Comments
 (0)