Skip to content

Commit

Permalink
Handle caching for gists in nginx
Browse files Browse the repository at this point in the history
  • Loading branch information
fkling committed Jan 30, 2017
1 parent beb4cc0 commit 11f91f9
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions server/handlers/gist/loadGist.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,6 @@ module.exports = function loadGist(req, res, next) {
gist.read() :
gist.getRevision(req.params.revisionid)
)
.then(response => {
res.append('Cache-Control', latest ? 'no-cache' : 'max-age=1800, public');
res.json(response.data);
})
.then(response => res.json(response.data))
.catch(next);
};

0 comments on commit 11f91f9

Please sign in to comment.