]> git.mxchange.org Git - friendica.git/blobdiff - src/Protocol/Diaspora.php
Merge branch 'develop' of https://github.com/friendica/friendica into develop
[friendica.git] / src / Protocol / Diaspora.php
index 00f4e1702d643779c6930f494dacc0b71882db62..5792d56b6eeef6cc0e28e6315cbb08f8ed939d6f 100644 (file)
@@ -949,6 +949,7 @@ class Diaspora
                                $person = DBA::selectFirst('fcontact', [], ['network' => Protocol::DIASPORA, 'addr' => $handle]);
                                if (!DBA::isResult($person)) {
                                        $person = $r;
+                                       $person['id'] = 0;
                                }
                        }
                }
@@ -1199,7 +1200,7 @@ class Diaspora
                );
 
                preg_replace_callback(
-                       "&\[url=/posts/([^\[\]]*)\](.*)\[\/url\]&Usi",
+                       "&\[url=/?posts/([^\[\]]*)\](.*)\[\/url\]&Usi",
                        function ($match) use ($item) {
                                self::fetchGuidSub($match, $item);
                        },
@@ -3429,12 +3430,9 @@ class Diaspora
                /// @todo - establish "all day" events in Friendica
                $eventdata["all_day"] = "false";
 
-               if (!$event['adjust']) {
+               $eventdata['timezone'] = 'UTC';
+               if (!$event['adjust'] && $user['timezone']) {
                        $eventdata['timezone'] = $user['timezone'];
-
-                       if ($eventdata['timezone'] == "") {
-                               $eventdata['timezone'] = 'UTC';
-                       }
                }
 
                if ($event['start']) {