function ping_broadcast_notice($notice) {
- if (!$notice->is_local) {
+ if ($notice->is_local != Notice::LOCAL_PUBLIC && $notice->is_local != Notice::LOCAL_NONPUBLIC) {
return true;
}
array('nickname' => $profile->nickname)),
$tags));
- $request = new HTTPClient($notify_url, HTTP_Request2::METHOD_POST);
- $request->setHeader('Content-Type', 'text/xml');
- $request->setBody($req);
- $httpResponse = $request->send();
+ $request = HTTPClient::start();
+ $httpResponse = $request->post($notify_url, array('Content-Type: text/xml'), $req);
if (!$httpResponse || mb_strlen($httpResponse->getBody()) == 0) {
common_log(LOG_WARNING,
return implode('|', $tags);
}
return NULL;
-}
\ No newline at end of file
+}