Merge pull request #477 from TheSerapher/issue-466
Fixing negative time since last block
This commit is contained in:
commit
81dc8d1627
@ -38,6 +38,7 @@ if (!$smarty->isCached('master.tpl', $smarty_cache_key)) {
|
||||
$now = new DateTime( "now" );
|
||||
if (!empty($aBlockData)) {
|
||||
$dTimeSinceLast = ($now->getTimestamp() - $aBlockData['time']);
|
||||
if ($dTimeSinceLast < 0) $dTimeSinceLast = 0;
|
||||
} else {
|
||||
$dTimeSinceLast = 0;
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user