use Friendica\Model\Post;
use Friendica\Model\Tag;
use Friendica\Model\User;
+use Friendica\Network\HTTPClient\Client\HttpClientAccept;
use Friendica\Network\Probe;
use Friendica\Util\Crypto;
use Friendica\Util\DateTimeFormat;
Logger::info("Fetch post from ".$source_url);
- $envelope = DI::httpClient()->fetch($source_url);
+ $envelope = DI::httpClient()->fetch($source_url, HttpClientAccept::MAGIC);
if ($envelope) {
Logger::info("Envelope was fetched.");
$x = self::verifyMagicEnvelope($envelope);
'author-id' => $author,
'owner-id' => $author,
'body' => $post,
- 'allow_cid' => $owner['allow_cid'],
- 'allow_gid' => $owner['allow_gid'],
- 'deny_cid' => $owner['deny_cid'],
- 'deny_gid' => $owner['deny_gid'],
+ 'allow_cid' => $owner['allow_cid'] ?? '',
+ 'allow_gid' => $owner['allow_gid']?? '',
+ 'deny_cid' => $owner['deny_cid'] ?? '',
+ 'deny_gid' => $owner['deny_gid'] ?? '',
];
if (!empty($item['allow_cid'] . $item['allow_gid'] . $item['deny_cid'] . $item['deny_gid'])) {