mirror of
https://github.com/friendica/friendica
synced 2025-04-27 14:30:11 +00:00
Merge pull request #8886 from annando/getidforurl-update
in "getidforurl" "no update" is now "update"
This commit is contained in:
commit
dd85f48e0d
28 changed files with 96 additions and 90 deletions
|
@ -445,9 +445,9 @@ class Processor
|
|||
|
||||
$item['network'] = Protocol::ACTIVITYPUB;
|
||||
$item['author-link'] = $activity['author'];
|
||||
$item['author-id'] = Contact::getIdForURL($activity['author'], 0, true);
|
||||
$item['author-id'] = Contact::getIdForURL($activity['author'], 0, false);
|
||||
$item['owner-link'] = $activity['actor'];
|
||||
$item['owner-id'] = Contact::getIdForURL($activity['actor'], 0, true);
|
||||
$item['owner-id'] = Contact::getIdForURL($activity['actor'], 0, false);
|
||||
|
||||
if (in_array(0, $activity['receiver']) && !empty($activity['unlisted'])) {
|
||||
$item['private'] = Item::UNLISTED;
|
||||
|
@ -511,13 +511,13 @@ class Processor
|
|||
$item['uid'] = $receiver;
|
||||
|
||||
if ($isForum) {
|
||||
$item['contact-id'] = Contact::getIdForURL($activity['actor'], $receiver, true);
|
||||
$item['contact-id'] = Contact::getIdForURL($activity['actor'], $receiver, false);
|
||||
} else {
|
||||
$item['contact-id'] = Contact::getIdForURL($activity['author'], $receiver, true);
|
||||
$item['contact-id'] = Contact::getIdForURL($activity['author'], $receiver, false);
|
||||
}
|
||||
|
||||
if (($receiver != 0) && empty($item['contact-id'])) {
|
||||
$item['contact-id'] = Contact::getIdForURL($activity['author'], 0, true);
|
||||
$item['contact-id'] = Contact::getIdForURL($activity['author'], 0, false);
|
||||
}
|
||||
|
||||
if (!empty($activity['directmessage'])) {
|
||||
|
|
|
@ -150,7 +150,7 @@ class Transmitter
|
|||
*/
|
||||
public static function getOutbox($owner, $page = null)
|
||||
{
|
||||
$public_contact = Contact::getIdForURL($owner['url'], 0, true);
|
||||
$public_contact = Contact::getIdForURL($owner['url'], 0, false);
|
||||
|
||||
$condition = ['uid' => 0, 'contact-id' => $public_contact, 'author-id' => $public_contact,
|
||||
'private' => [Item::PUBLIC, Item::UNLISTED], 'gravity' => [GRAVITY_PARENT, GRAVITY_COMMENT],
|
||||
|
|
|
@ -221,7 +221,7 @@ class OStatus
|
|||
}
|
||||
|
||||
// Ensure that we are having this contact (with uid=0)
|
||||
$cid = Contact::getIdForURL($aliaslink, 0, true);
|
||||
$cid = Contact::getIdForURL($aliaslink, 0, false);
|
||||
|
||||
if ($cid) {
|
||||
$fields = ['url', 'nurl', 'name', 'nick', 'alias', 'about', 'location'];
|
||||
|
@ -2220,7 +2220,7 @@ class OStatus
|
|||
}
|
||||
|
||||
$check_date = $feed_mode ? '' : DateTimeFormat::utc($last_update);
|
||||
$authorid = Contact::getIdForURL($owner["url"], 0, true);
|
||||
$authorid = Contact::getIdForURL($owner["url"], 0, false);
|
||||
|
||||
$condition = ["`uid` = ? AND `received` > ? AND NOT `deleted`
|
||||
AND `private` != ? AND `visible` AND `wall` AND `parent-network` IN (?, ?)",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue