Move Temporal::convert() to DateTimeFormat::convert()

This commit is contained in:
Hypolite Petovan 2018-01-26 21:39:02 -05:00
parent 13fb4a312d
commit 1900da6c42
15 changed files with 77 additions and 77 deletions

View file

@ -1,7 +1,7 @@
<?php
use Friendica\Core\L10n;
use Friendica\Util\Temporal;
use Friendica\Util\DateTimeFormat;
/**
* @param mixed $obj
@ -101,9 +101,9 @@ function wdcal_print_feed($base_path = "")
else $type = Sabre\VObject\Property\DateTime::LOCALTZ;
$datetime_start = new Sabre\VObject\Property\DateTime("DTSTART");
$datetime_start->setDateTime(new DateTime(date(Temporal::MYSQL, IntVal($_REQUEST["CalendarStartTime"]))), $type);
$datetime_start->setDateTime(new DateTime(date(DateTimeFormat::MYSQL, IntVal($_REQUEST["CalendarStartTime"]))), $type);
$datetime_end = new Sabre\VObject\Property\DateTime("DTEND");
$datetime_end->setDateTime(new DateTime(date(Temporal::MYSQL, IntVal($_REQUEST["CalendarEndTime"]))), $type);
$datetime_end->setDateTime(new DateTime(date(DateTimeFormat::MYSQL, IntVal($_REQUEST["CalendarEndTime"]))), $type);
$component->add($datetime_start);
$component->add($datetime_end);
@ -183,9 +183,9 @@ function wdcal_print_feed($base_path = "")
else $type = Sabre\VObject\Property\DateTime::LOCALTZ;
$datetime_start = new Sabre\VObject\Property\DateTime("DTSTART");
$datetime_start->setDateTime(new DateTime(date(Temporal::MYSQL, IntVal($_REQUEST["CalendarStartTime"]))), $type);
$datetime_start->setDateTime(new DateTime(date(DateTimeFormat::MYSQL, IntVal($_REQUEST["CalendarStartTime"]))), $type);
$datetime_end = new Sabre\VObject\Property\DateTime("DTEND");
$datetime_end->setDateTime(new DateTime(date(Temporal::MYSQL, IntVal($_REQUEST["CalendarEndTime"]))), $type);
$datetime_end->setDateTime(new DateTime(date(DateTimeFormat::MYSQL, IntVal($_REQUEST["CalendarEndTime"]))), $type);
$component->__unset("DTSTART");
$component->__unset("DTEND");