diff options
author | Brion Vibber <brion@pobox.com> | 2010-11-03 17:25:29 -0700 |
---|---|---|
committer | Brion Vibber <brion@pobox.com> | 2010-11-03 17:25:29 -0700 |
commit | 4f63e3be7dc12383d4e66bdd4db25dd6fea9abba (patch) | |
tree | 422567accad7da828b499d2e4b179bd28afb924d /README | |
parent | 2692b5fc8400d04f25823e5bc00e3d4f98100a3b (diff) |
Fix for ticket #2804: bad non-cache fallback code for dupe checks of prolific posters
The old code attempted to compare the value of the notice.created field against now() directly, which tends to explode in our current systems. now() comes up as the server/connection local timezone generally, while the created field is currently set as hardcoded UTC from the web servers. This would lead to breakage when we got a difference in seconds that's several hours off in either direction (depending on the local timezone). New code calculates a threshold by subtracting the number of seconds from the current UNIX timestamp and passing that in in correct format for a simple comparison. As a bonus, this should also be more efficient, as it should be able to follow the index on profile_id and created.
Diffstat (limited to 'README')
0 files changed, 0 insertions, 0 deletions