mirror of
https://github.com/friendica/friendica
synced 2025-04-28 13:44:25 +02:00
Renamed the contact relationship functions
This commit is contained in:
parent
2cb74909c0
commit
bdbfffafea
4 changed files with 10 additions and 10 deletions
|
@ -2255,22 +2255,22 @@ class DFRN
|
|||
// This function once was responsible for DFRN and OStatus.
|
||||
if (activity_match($item["verb"], ACTIVITY_FOLLOW)) {
|
||||
logger("New follower");
|
||||
Contact::newFollower($importer, $contact, $item, $nickname);
|
||||
Contact::addRelationship($importer, $contact, $item, $nickname);
|
||||
return false;
|
||||
}
|
||||
if (activity_match($item["verb"], ACTIVITY_UNFOLLOW)) {
|
||||
logger("Lost follower");
|
||||
Contact::loseFollower($importer, $contact, $item);
|
||||
Contact::removeFollower($importer, $contact, $item);
|
||||
return false;
|
||||
}
|
||||
if (activity_match($item["verb"], ACTIVITY_REQ_FRIEND)) {
|
||||
logger("New friend request");
|
||||
Contact::newFollower($importer, $contact, $item, $nickname, true);
|
||||
Contact::addRelationship($importer, $contact, $item, $nickname, true);
|
||||
return false;
|
||||
}
|
||||
if (activity_match($item["verb"], ACTIVITY_UNFRIEND)) {
|
||||
logger("Lost sharer");
|
||||
Contact::loseSharer($importer, $contact, $item);
|
||||
Contact::removeSharer($importer, $contact, $item);
|
||||
return false;
|
||||
}
|
||||
} else {
|
||||
|
|
|
@ -2502,7 +2502,7 @@ class Diaspora
|
|||
return true;
|
||||
} else {
|
||||
logger("Author ".$author." doesn't want to follow us anymore.", LOGGER_DEBUG);
|
||||
Contact::loseFollower($importer, $contact);
|
||||
Contact::removeFollower($importer, $contact);
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -456,12 +456,12 @@ class OStatus
|
|||
}
|
||||
|
||||
if ($item["verb"] == ACTIVITY_FOLLOW) {
|
||||
Contact::newFollower($importer, $contact, $item, $nickname);
|
||||
Contact::addRelationship($importer, $contact, $item, $nickname);
|
||||
continue;
|
||||
}
|
||||
|
||||
if ($item["verb"] == NAMESPACE_OSTATUS."/unfollow") {
|
||||
Contact::loseFollower($importer, $contact, $item, $dummy);
|
||||
Contact::removeFollower($importer, $contact, $item, $dummy);
|
||||
continue;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue