Status: Closed (View Workflow)
There are some cases when future dates display as less than a minute ago, which is really annoying for mods.
And also may affect phpbb on end of ban/poll dates.
Set your date-format to something with || so it's shortened
than put something like:
into your index.php
what you would expect is:
but what you get is:
the reason for this is, from the current code:
$delta is -3600 and -7200 so both times <= 3600 and (($now / 60) % 60) == (($gmepoch / 60) % 60) is also true, as they are the same minute (doesn't care about the hour yet).
two possibilities I'd suggest:
- Remove detecting the minute, so it's only displayed as "less than a minute ago, when it is ago or the 5 seconds in future:
- or if you want to keep the detecting of the whole minute (which I think is wrong, as it may still take 59 seconds in some cases ) add a "$delta > -60 &&" to the minute-check:
I'd prefer the first version.