snac2

Fork of https://codeberg.org/grunfink/snac2
git clone https://git.inz.fi/snac2
Log | Files | Refs | README | LICENSE

commit 78bd0263ce56ce8d8544389971daa3d6cdd5c25e
parent 02bc18eb118fcd93f5cd90a056f7b78dfe64382f
Author: default <nobody@localhost>
Date:   Fri, 14 Feb 2025 10:08:26 +0100

html_footer() now receives an optional snac *user argument.

Diffstat:
Mhtml.c | 12+++++-------
1 file changed, 5 insertions(+), 7 deletions(-)

diff --git a/html.c b/html.c @@ -2585,10 +2585,8 @@ xs_html *html_entry(snac *user, xs_dict *msg, int read_only, } -xs_html *html_footer(void) +xs_html *html_footer(const snac *user) { - const snac *user = NULL; - return xs_html_tag("div", xs_html_attr("class", "snac-footer"), xs_html_tag("a", @@ -2895,7 +2893,7 @@ xs_str *html_timeline(snac *user, const xs_list *list, int read_only, } xs_html_add(body, - html_footer()); + html_footer(user)); return xs_html_render_s(html, "<!DOCTYPE html>\n"); } @@ -3064,7 +3062,7 @@ xs_str *html_people(snac *user) html_user_head(user, NULL, NULL), xs_html_add(html_user_body(user, 0), lists, - html_footer())); + html_footer(user))); return xs_html_render_s(html, "<!DOCTYPE html>\n"); } @@ -3314,7 +3312,7 @@ xs_str *html_notifications(snac *user, int skip, int show) xs_set_free(&rep); xs_html_add(body, - html_footer()); + html_footer(user)); /* set the check time to now */ xs *dummy = notify_check_time(user, 1); @@ -3569,7 +3567,7 @@ int html_get_handler(const xs_dict *req, const char *q_path, html_user_head(&snac, NULL, NULL), xs_html_add(html_user_body(&snac, 0), page, - html_footer())); + html_footer(user))); *body = xs_html_render_s(html, "<!DOCTYPE html>\n"); *b_size = strlen(*body);