Remove most calls to date_default_timezone_* calls
- It was wrongly used to set the node-wide ot user-specific timezone - It is now fully managed from the App object - Add a static variable to DateTimeFormat maintain the convenient local() method
This commit is contained in:
parent
08c24fd4fa
commit
6db211568a
11 changed files with 35 additions and 36 deletions
|
@ -686,7 +686,7 @@ function item_post(App $a) {
|
|||
Hook::callAll('post_local',$datarray);
|
||||
|
||||
if (!empty($_REQUEST['scheduled_at'])) {
|
||||
$scheduled_at = DateTimeFormat::convert($_REQUEST['scheduled_at'], 'UTC', $a->getTimezone());
|
||||
$scheduled_at = DateTimeFormat::convert($_REQUEST['scheduled_at'], 'UTC', $a->getTimeZone());
|
||||
if ($scheduled_at > DateTimeFormat::utcNow()) {
|
||||
unset($datarray['created']);
|
||||
unset($datarray['edited']);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue