Merge branch 'develop' of https://github.com/syuilo/misskey into develop
This commit is contained in:
@ -76,7 +76,7 @@ router.get('/notes/:note', async (ctx, next) => {
|
||||
}
|
||||
|
||||
ctx.body = pack(await renderNote(note, false));
|
||||
ctx.set('Cache-Control', 'public, max-age=180');
|
||||
ctx.set('Cache-Control', 'private, max-age=0, must-revalidate');
|
||||
setResponseType(ctx);
|
||||
});
|
||||
|
||||
|
@ -9,8 +9,8 @@ export default function(ctx: Koa.Context, user: ILocalUser, redirect = false) {
|
||||
path: '/',
|
||||
domain: config.hostname,
|
||||
// SEE: https://github.com/koajs/koa/issues/974
|
||||
//secure: config.url.startsWith('https'),
|
||||
secure: false,
|
||||
// When using a SSL proxy it should be configured to add the "X-Forwarded-Proto: https" header
|
||||
secure: config.url.startsWith('https'),
|
||||
httpOnly: false,
|
||||
expires: new Date(Date.now() + expires),
|
||||
maxAge: expires
|
||||
|
@ -111,7 +111,7 @@ router.get('/notes/:note', async ctx => {
|
||||
note: _note,
|
||||
summary: getNoteSummary(_note)
|
||||
});
|
||||
ctx.set('Cache-Control', 'public, max-age=180');
|
||||
ctx.set('Cache-Control', 'private, max-age=0, must-revalidate');
|
||||
} else {
|
||||
ctx.status = 404;
|
||||
}
|
||||
|
Reference in New Issue
Block a user