all repos — cgit @ 00e3a3ecda77bf5ab149db0940c549f1bb618de4

a hyperfast web frontend for git written in c

cache: id means static, even if head is specified too

Pages like /commit?h=wip&id=8a335ce618ba77fbf05148d6f8be17bd48ba4340
were being marked as dynamic, because of h=wip, when it should be
static, because of id=.

Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Jason A. Donenfeld Jason@zx2c4.com
Tue, 28 May 2013 16:43:02 +0200
commit

00e3a3ecda77bf5ab149db0940c549f1bb618de4

parent

61ff10065b579fa38182fcf10cc7e63839acd53c

1 files changed, 3 insertions(+), 3 deletions(-)

jump to
M cgit.ccgit.c

@@ -928,11 +928,11 @@

if (!strcmp(ctx.qry.page, "about")) return ctx.cfg.cache_about_ttl; - if (ctx.qry.has_symref) - return ctx.cfg.cache_dynamic_ttl; - if (ctx.qry.has_sha1) return ctx.cfg.cache_static_ttl; + + if (ctx.qry.has_symref) + return ctx.cfg.cache_dynamic_ttl; return ctx.cfg.cache_repo_ttl; }