]> git.mxchange.org Git - friendica.git/commitdiff
Set post type if relay post was received via DFRN
authorMichael <heluecht@pirati.ca>
Sat, 9 Jan 2021 18:17:49 +0000 (18:17 +0000)
committerMichael <heluecht@pirati.ca>
Sat, 9 Jan 2021 18:17:49 +0000 (18:17 +0000)
src/Protocol/DFRN.php

index 0518695c0e07b843cb37c3fc289503d45ef13afa..26b68b15b9f3348f66d7204e09dd9506ec31d760 100644 (file)
@@ -31,6 +31,7 @@ use Friendica\Core\Protocol;
 use Friendica\Database\DBA;
 use Friendica\DI;
 use Friendica\Model\Contact;
+use Friendica\Model\Conversation;
 use Friendica\Model\Event;
 use Friendica\Model\FContact;
 use Friendica\Model\Item;
@@ -2634,6 +2635,10 @@ class DFRN
                $header["contact-id"] = $importer["id"];
                $header["direction"] = $direction;
 
+               if ($direction == Conversation::RELAY) {
+                       $header['post-type'] = Item::PT_RELAY;
+               }
+
                // Update the contact table if the data has changed
 
                // The "atom:author" is only present in feeds