aboutsummaryrefslogtreecommitdiff
path: root/src/Routes/Home.c
blob: 81370baeb00b7439ee0979a5ae6cc7a09443c34b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#include "Home.h"
#include <stdlib.h>

int home_handler(UrlParams *params) {
    (void)params;
    TemplateContext ctx = new_context();
    char *rendered_html = render_template("home.html", &ctx);
    send_response(rendered_html);

    free(rendered_html);
    free_context(&ctx);

    return 0;
}