ircd: Use fmt flags to ago(); add flag for blank postfix label.

This commit is contained in:
Jason Volk 2022-08-16 13:17:55 -07:00
parent a8b5912e98
commit d1a8724296
1 changed files with 3 additions and 2 deletions

View File

@ -96,8 +96,9 @@ ircd::ago(const mutable_buffer &buf,
char tmp[64];
return fmt::sprintf
{
buf, "%s ago",
pretty(tmp, diff, fmt),
buf, "%s%s",
pretty(tmp, diff, fmt & 0x01),
(fmt & 0x2)? string_view{}: " ago"_sv,
};
}