log the D* publc messages
This commit is contained in:
parent
5a6a3cab8e
commit
d7243be2ea
1 changed files with 4 additions and 1 deletions
|
@ -8,15 +8,18 @@ require_once('include/contact_selectors.php');
|
||||||
|
|
||||||
function diaspora_dispatch_public($msg) {
|
function diaspora_dispatch_public($msg) {
|
||||||
|
|
||||||
$r = q("SELECT `user`.* FROM `user` WHERE `user`.`uid` IN ( SELECT `uid` FROM `contact` WHERE `network` = '%s' AND `addr` = '%s' ) ",
|
$r = q("SELECT `user`.* FROM `user` WHERE `user`.`uid` IN ( SELECT `contact`.`uid` FROM `contact` WHERE `contact`.`network` = '%s' AND `contact`.`addr` = '%s' ) ",
|
||||||
dbesc(NETWORK_DIASPORA),
|
dbesc(NETWORK_DIASPORA),
|
||||||
dbesc($msg['author'])
|
dbesc($msg['author'])
|
||||||
);
|
);
|
||||||
if(count($r)) {
|
if(count($r)) {
|
||||||
foreach($r as $rr) {
|
foreach($r as $rr) {
|
||||||
|
logger('diaspora_public: delivering to: ' . $rr['username']);
|
||||||
diaspora_dispatch($rr,$msg);
|
diaspora_dispatch($rr,$msg);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
logger('diaspora_public: no subscribers');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue