mirror of
https://github.com/friendica/friendica
synced 2025-04-26 09:10:15 +00:00
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
|
@ -488,10 +488,7 @@ class DFRN
|
|||
XML::addElement($doc, $author, "poco:note", $profile["about"]);
|
||||
XML::addElement($doc, $author, "poco:preferredUsername", $profile["nickname"]);
|
||||
|
||||
$savetz = date_default_timezone_get();
|
||||
date_default_timezone_set($profile["timezone"]);
|
||||
XML::addElement($doc, $author, "poco:utcOffset", date("P"));
|
||||
date_default_timezone_set($savetz);
|
||||
XML::addElement($doc, $author, "poco:utcOffset", DateTimeFormat::timezoneNow($profile["timezone"], "P"));
|
||||
|
||||
if (trim($profile["homepage"]) != "") {
|
||||
$urls = $doc->createElement("poco:urls");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue