]> git.mxchange.org Git - friendica.git/commitdiff
Fix transmission of events to Diaspora
authorMichael <heluecht@pirati.ca>
Thu, 7 Dec 2023 06:45:23 +0000 (06:45 +0000)
committerMichael <heluecht@pirati.ca>
Thu, 7 Dec 2023 06:45:23 +0000 (06:45 +0000)
src/Content/Text/BBCode.php
src/Protocol/Diaspora.php

index e9eeba61181e376c72bb95820a01c74a7175f5e8..3bb9fda125b1e22b62ba0c75f3285c0ca37e8d86 100644 (file)
@@ -2171,6 +2171,9 @@ class BBCode
                // Maybe we should make this newline at every time before a quote.
                $text = str_replace(['</a><blockquote>'], ['</a><br><blockquote>'], $text);
 
+               // The converter doesn't convert these elements
+               $text = str_replace(['<div>', '</div>'], ['<p>', '</p>'], $text);
+
                // Now convert HTML to Markdown
                $text = HTML::toMarkdown($text);
 
index cc3016aae912c2e60079a09869292eee39e85d28..3f456a69755d0ef6e718ae202d39802bf7b24f7a 100644 (file)
@@ -3310,7 +3310,7 @@ class Diaspora
 
                $result = DI::cache()->get($cachekey);
                if (!is_null($result)) {
-                       return $result;
+//                     return $result;
                }
 
                $myaddr = self::myHandle($owner);
@@ -3403,7 +3403,8 @@ class Diaspora
                        if ($item['event-id'] > 0) {
                                $event = self::buildEvent($item['event-id']);
                                if (count($event)) {
-                                       $message['event'] = $event;
+                                       // Deactivated, since Diaspora seems to have problems with the processing.
+                                       // $message['event'] = $event;
 
                                        if (
                                                !empty($event['location']['address']) &&