return;
}
- $own_user = Contact::selectFirst(['url', 'alias'], ['uid' => $notification_data['uid'], 'poll' => 'tumblr::'.$page]);
+ $own_user = Contact::selectFirst(['url', 'alias'], ['uid' => $notification_data['uid'], 'poll' => 'tumblr::' . $page]);
if ($own_user) {
$notification_data['profiles'][] = $own_user['url'];
$notification_data['profiles'][] = $own_user['alias'];
return null;
}
+ if (is_array($data->response->blog)) {
+ Logger::warning('Unexpected blog format', ['blog' => $blog, 'data' => $data]);
+ return null;
+ }
+
$baseurl = 'https://tumblr.com';
$url = $baseurl . '/' . $data->response->blog->name;
'priority' => 0,
'guid' => $data->response->blog->uuid,
'about' => HTML::toBBCode($data->response->blog->description),
- 'photo' => $data->response->blog->avatar[0]->url,
- 'header' => $data->response->blog->theme->header_image_focused,
+ 'photo' => $data->response->blog->avatar[0]->url,
+ 'header' => $data->response->blog->theme->header_image_focused,
];
}