mirror of
https://github.com/friendica/friendica
synced 2024-12-22 22:00:16 +00:00
OStatus: Only posts from followers will be imported (Issue 4369)
This commit is contained in:
parent
306dd382f3
commit
23718aeae3
1 changed files with 9 additions and 6 deletions
|
@ -72,8 +72,9 @@ class OStatus
|
|||
|
||||
$contact = null;
|
||||
if ($aliaslink != '') {
|
||||
$condition = ["`uid` = ? AND `alias` = ? AND `network` != ?",
|
||||
$importer["uid"], $aliaslink, NETWORK_STATUSNET];
|
||||
$condition = ["`uid` = ? AND `alias` = ? AND `network` != ? AND `rel` IN (?, ?)",
|
||||
$importer["uid"], $aliaslink, NETWORK_STATUSNET,
|
||||
CONTACT_IS_SHARING, CONTACT_IS_FRIEND];
|
||||
$contact = dba::selectFirst('contact', [], $condition);
|
||||
}
|
||||
|
||||
|
@ -82,14 +83,16 @@ class OStatus
|
|||
$aliaslink = $author["author-link"];
|
||||
}
|
||||
|
||||
$condition = ["`uid` = ? AND `nurl` IN (?, ?) AND `network` != ?", $importer["uid"],
|
||||
normalise_link($author["author-link"]), normalise_link($aliaslink), NETWORK_STATUSNET];
|
||||
$condition = ["`uid` = ? AND `nurl` IN (?, ?) AND `network` != ? AND `rel` IN (?, ?)",
|
||||
$importer["uid"], normalise_link($author["author-link"]), normalise_link($aliaslink),
|
||||
NETWORK_STATUSNET, CONTACT_IS_SHARING, CONTACT_IS_FRIEND];
|
||||
$contact = dba::selectFirst('contact', [], $condition);
|
||||
}
|
||||
|
||||
if (!DBM::is_result($contact) && ($addr != '')) {
|
||||
$condition = ["`uid` = ? AND `addr` = ? AND `network` != ?",
|
||||
$importer["uid"], $addr, NETWORK_STATUSNET];
|
||||
$condition = ["`uid` = ? AND `addr` = ? AND `network` != ? AND `rel` IN (?, ?)",
|
||||
$importer["uid"], $addr, NETWORK_STATUSNET,
|
||||
CONTACT_IS_SHARING, CONTACT_IS_FRIEND];
|
||||
$contact = dba::selectFirst('contact', [], $condition);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue