From d8a045c91469b1d121b8fd14dffaa367b194831d Mon Sep 17 00:00:00 2001 From: Bryce Kwon Date: Sun, 6 Sep 2026 21:46:52 -1000 Subject: Clean up the whole tree --- source/ui-tag.c | 25 ++++++++----------------- 1 file changed, 8 insertions(+), 17 deletions(-) (limited to 'source/ui-tag.c') diff --git a/source/ui-tag.c b/source/ui-tag.c index 469f209..ec8cd54 100644 --- a/source/ui-tag.c +++ b/source/ui-tag.c @@ -55,17 +55,14 @@ static void print_message(char *msg) } } -static void print_annotated_tag(const char *revname, - const struct object_id *oid) +static void print_annotated_tag(const char *revname, const struct object_id *oid) { struct tag *tag; struct taginfo *info; tag = lookup_tag(the_repository, oid); - if (!tag || parse_tag(the_repository, tag) || - !(info = cgit_parse_tag(tag))) { - cgit_print_error_page(500, "Internal Server Error", - "Bad tag object: %s", revname); + if (!tag || parse_tag(the_repository, tag) || !(info = cgit_parse_tag(tag))) { + cgit_print_error_page(500, "Internal Server Error", "Bad tag object: %s", revname); return; } @@ -76,20 +73,16 @@ static void print_annotated_tag(const char *revname, htmlf(" (%s)\n", oid_to_hex(oid)); if (info->tagger_date > 0) { html("tag date\n"); } if (info->tagger) { html("tagged by"); // A tag can carry a tagger with no address, and a filter must // not be handed a NULL argument. - cgit_open_filter(ctx.repo->email_filter, - info->tagger_email ? info->tagger_email : "", - "tag"); + cgit_open_filter(ctx.repo->email_filter, info->tagger_email ? info->tagger_email : "", "tag"); html_txt(info->tagger); if (info->tagger_email && ctx.cfg.enable_plain_email) { html(" "); @@ -132,14 +125,12 @@ void cgit_print_tag(char *revname) strbuf_addf(&fullref, "refs/tags/%s", revname); if (repo_get_oid(the_repository, fullref.buf, &oid)) { - cgit_print_error_page(404, "Not Found", - "Bad tag reference: %s", revname); + cgit_print_error_page(404, "Not Found", "Bad tag reference: %s", revname); goto cleanup; } obj = parse_object(the_repository, &oid); if (!obj) { - cgit_print_error_page(500, "Internal Server Error", - "Bad object id: %s", oid_to_hex(&oid)); + cgit_print_error_page(500, "Internal Server Error", "Bad object id: %s", oid_to_hex(&oid)); goto cleanup; } if (obj->type == OBJ_TAG) -- cgit v2.8.0