aboutsummaryrefslogtreecommitdiffstats
path: root/cmd.c
diff options
context:
space:
mode:
Diffstat (limited to 'cmd.c')
-rw-r--r--cmd.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/cmd.c b/cmd.c
index 0eb75b1..dd1acd1 100644
--- a/cmd.c
+++ b/cmd.c
@@ -193,14 +193,13 @@ struct cgit_cmd *cgit_get_cmd(void)
def_cmd(tree, 1, 1, 0),
};
int i;
-
if (ctx.qry.page == NULL) {
if (ctx.repo)
- ctx.qry.page = "summary";
+ ctx.qry.page = ctx.cfg.default_index;
else
ctx.qry.page = "repolist";
}
-
+
for (i = 0; i < sizeof(cmds)/sizeof(*cmds); i++)
if (!strcmp(ctx.qry.page, cmds[i].name))
return &cmds[i];