1
0
Fork 0
mirror of https://github.com/transmission/transmission synced 2025-01-03 13:35:36 +00:00

fix(remote): Fix tr_strltime to output days correctly (#4506)

This commit is contained in:
Luukas Pörtfors 2023-01-01 21:01:48 +02:00 committed by GitHub
parent 611b181a99
commit a46bcf7381
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -143,7 +143,7 @@ static std::string tr_strltime(time_t seconds)
if (days > 0)
{
auto const dstr = fmt::format(FMT_STRING("{:d} {:s}"), hours, tr_ngettext("day", "days", days));
auto const dstr = fmt::format(FMT_STRING("{:d} {:s}"), days, tr_ngettext("day", "days", days));
tmpstr = days >= 4 || hours == 0 ? dstr : fmt::format(FMT_STRING("{:s}, {:s}"), dstr, hstr);
}
else if (hours > 0)