Skip to content

Commit d20a263

Browse files
committed
Calculate time better for is expired yet check
1 parent 5a3d030 commit d20a263

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

controller/helper.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -201,7 +201,7 @@ public function get_date($time = 'now')
201201
*/
202202
public function is_expired($row)
203203
{
204-
$latest_timezone_end = time() - (12 * 3600); // UTC-12 is the last timezone
204+
$latest_timezone_end = strtotime('now -12 hours'); // UTC-12 is the last timezone
205205
if ((int) $row['ad_end_date'] > 0 && (int) $row['ad_end_date'] < $latest_timezone_end)
206206
{
207207
return true;

0 commit comments

Comments
 (0)