Permalink
Browse files

force delayed_publish time comparisons to UTC.

  • Loading branch information...
friendica committed May 30, 2013
1 parent 7073200 commit 8b87eee86982feddfa56c9b585dce37b9337900b
Showing with 2 additions and 2 deletions.
  1. +2 −2 include/items.php
@@ -1462,8 +1462,8 @@ function item_store($arr,$force_parent = false) {
// handle time travelers
// Allow a bit of fudge in case somebody just has a slightly slow/fast clock
$d1 = new DateTime('now +10 minutes');
$d2 = new DateTime($arr['created']);
$d1 = new DateTime('now +10 minutes', new DateTimeZone('UTC'));
$d2 = new DateTime($arr['created'] . '+00:00');
if($d2 > $d1)
$arr['item_restrict'] = $arr['item_restrict'] | ITEM_DELAYED_PUBLISH;

2 comments on commit 8b87eee

@unary

This comment has been minimized.

Contributor

unary replied May 30, 2013

This did the trick for me. Thanks.

@friendica

This comment has been minimized.

Owner

friendica replied May 30, 2013

According to the manual it shouldn't have been necessary. But glad it worked.

Please sign in to comment.