Skip to content
This repository has been archived by the owner on Jan 28, 2024. It is now read-only.

Commit

Permalink
chore(routes/docs/openapi): reduce cache max-age from 60 to 30 minutes
Browse files Browse the repository at this point in the history
  • Loading branch information
Fdawgs committed Jan 20, 2023
1 parent d9fd504 commit a3bf683
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/routes/docs/openapi/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ async function route(server, options) {
}
},
handler: (req, res) => {
res.header("cache-control", "public, max-age=3600")
res.header("cache-control", "public, max-age=1800")
.removeHeader("pragma")
.removeHeader("expires")
.removeHeader("surrogate-control")
Expand Down
2 changes: 1 addition & 1 deletion src/routes/docs/openapi/route.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ describe("OpenAPI Route", () => {

expect(JSON.parse(response.payload)).toHaveProperty("openapi");
expect(response.headers).toMatchObject({
"cache-control": "public, max-age=3600",
"cache-control": "public, max-age=1800",
});
expect(response.statusCode).toBe(200);
});
Expand Down

0 comments on commit a3bf683

Please sign in to comment.