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

Commit

Permalink
chore: Add cache to RSS
Browse files Browse the repository at this point in the history
  • Loading branch information
potato4d committed Nov 10, 2019
1 parent cb47a21 commit cfebf21
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions api/routes/feedRoutes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ export async function getPersonalFeed(req: Request, res: Response) {
articles: sortBy(articles, ['unixtime']),
time: dayjs().format()
})
res.header('Cache-Control', 'max-age=7200')
res.header('Content-Type', 'application/atom+xml; charset=utf-8')
res.write(xml)
res.end()
Expand Down

0 comments on commit cfebf21

Please sign in to comment.