use Friendica\Core\Logger;
use Friendica\Core\Protocol;
use Friendica\Core\Renderer;
-use Friendica\Core\System;
use Friendica\Core\Worker;
use Friendica\Database\DBA;
use Friendica\DI;
function bluesky_get_uri(stdClass $post): string
{
if (empty($post->cid)) {
- Logger::info('Invalid URI', ['post' => $post, 'callstack' => System::callstack(10, 0, true)]);
+ Logger::info('Invalid URI', ['post' => $post]);
return '';
}
return $post->uri . ':' . $post->cid;
function bluesky_process_thread(stdClass $thread, int $uid, array $cdata, int $level): string
{
if (empty($thread->post)) {
- Logger::info('Invalid post', ['post' => $thread, 'callstack' => System::callstack(10, 0, true)]);
+ Logger::info('Invalid post', ['post' => $thread]);
return '';
}
$uri = bluesky_get_uri($thread->post);
return;
}
- $lang = $iso639->languageByCode1($iso2);
+ $lang = $iso639->languageByCode1(substr($iso2, 0, 2));
} else {
$opts = $hook_data['item']['postopts'];
if (!$opts) {