forked from GNUsocial/gnu-social
change PuSH plugin to use whoGets()
This commit is contained in:
parent
9cfea6d051
commit
d902de139c
@ -95,14 +95,16 @@ class PubSubHubBubPlugin extends Plugin
|
|||||||
}
|
}
|
||||||
|
|
||||||
//feed of each user that subscribes to the notice's author
|
//feed of each user that subscribes to the notice's author
|
||||||
$notice_inbox = new Notice_inbox();
|
|
||||||
$notice_inbox->notice_id = $notice->id;
|
$ni = $notice->whoGets();
|
||||||
if ($notice_inbox->find()) {
|
|
||||||
while ($notice_inbox->fetch()) {
|
foreach (array_keys($ni) as $user_id) {
|
||||||
$user = User::staticGet('id',$notice_inbox->user_id);
|
$user = User::staticGet('id', $user_id);
|
||||||
$feeds[]=common_local_url('ApiTimelineUser',array('id' => $user->nickname, 'format'=>'rss'));
|
if (empty($user)) {
|
||||||
$feeds[]=common_local_url('ApiTimelineUser',array('id' => $user->nickname, 'format'=>'atom'));
|
continue;
|
||||||
}
|
}
|
||||||
|
$feeds[]=common_local_url('ApiTimelineUser',array('id' => $user->nickname, 'format'=>'rss'));
|
||||||
|
$feeds[]=common_local_url('ApiTimelineUser',array('id' => $user->nickname, 'format'=>'atom'));
|
||||||
}
|
}
|
||||||
|
|
||||||
//feed of user replied to
|
//feed of user replied to
|
||||||
|
Loading…
Reference in New Issue
Block a user