Add Temporal::timezoneNow() shorthand for Temporal::convert()
This commit is contained in:
@@ -276,8 +276,8 @@ function events_content(App $a) {
|
||||
// The view mode part is similiar to /mod/cal.php
|
||||
if ($mode == 'view') {
|
||||
|
||||
$thisyear = Temporal::convert('now', date_default_timezone_get(), 'UTC', 'Y');
|
||||
$thismonth = Temporal::convert('now', date_default_timezone_get(), 'UTC', 'm');
|
||||
$thisyear = Temporal::timezoneNow(date_default_timezone_get(), 'Y');
|
||||
$thismonth = Temporal::timezoneNow(date_default_timezone_get(), 'm');
|
||||
if (! $y) {
|
||||
$y = intval($thisyear);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user