Current time: 03-20-2010, 03:27 AM Hello There, Guest! (LoginRegister)


 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[F] Time calculation bugs in promotions.php
08-21-2008, 11:50 AM
Post: #1
[F] Time calculation bugs in promotions.php
I found a few bugs from the time difference calculation in inc/tasks/promotions.php, which make the registration age requirement 7 times larger than it should be, when using months or years as a measure:

line 52 (months):
$regdate = $promotion['registered']*60*60*24*7*30;
should be:
$regdate = $promotion['registered']*60*60*24*30;

line 55 (years):
$regdate = $promotion['registered']*60*60*24*7*365;
should be:
$regdate = $promotion['registered']*60*60*24*365;

The header says:
* $Id: promotions.php 3883 2008-06-05 00:38:28Z Tikitiki $
Visit this user's website Find all posts by this user
08-21-2008, 07:59 PM
Post: #2
[F] Time calculation bugs in promotions.php
Thank you for your bug report.

This bug has been fixed in our internal code repository. Please note that the problem will not be fixed here until these forums are updated.

[Image: ryangordon.png]
My Blog - My Mods
Visit this user's website Find all posts by this user


Forum Jump: