mirror of
https://github.com/friendica/friendica
synced 2025-04-24 08:30:11 +00:00
We now use the new account-user-view (and fixed the function name)
This commit is contained in:
parent
780d9f1793
commit
d267ba999c
17 changed files with 97 additions and 36 deletions
|
@ -52,7 +52,7 @@ class Lists extends BaseApi
|
|||
|
||||
$lists = [];
|
||||
|
||||
$cdata = Contact::getPublicAndUserContacID($id, $uid);
|
||||
$cdata = Contact::getPublicAndUserContactID($id, $uid);
|
||||
if (!empty($cdata['user'])) {
|
||||
$groups = DBA::select('group_member', ['gid'], ['contact-id' => $cdata['user']]);
|
||||
while ($group = DBA::fetch($groups)) {
|
||||
|
|
|
@ -45,7 +45,7 @@ class Note extends BaseApi
|
|||
'comment' => '',
|
||||
]);
|
||||
|
||||
$cdata = Contact::getPublicAndUserContacID($parameters['id'], $uid);
|
||||
$cdata = Contact::getPublicAndUserContactID($parameters['id'], $uid);
|
||||
if (empty($cdata['user'])) {
|
||||
DI::mstdnError()->RecordNotFound();
|
||||
}
|
||||
|
|
|
@ -46,7 +46,7 @@ class VerifyCredentials extends BaseApi
|
|||
DI::mstdnError()->InternalError();
|
||||
}
|
||||
|
||||
$cdata = Contact::getPublicAndUserContacID($self['id'], $uid);
|
||||
$cdata = Contact::getPublicAndUserContactID($self['id'], $uid);
|
||||
if (empty($cdata)) {
|
||||
DI::mstdnError()->InternalError();
|
||||
}
|
||||
|
|
|
@ -205,7 +205,7 @@ abstract class ContactEndpoint extends BaseApi
|
|||
|
||||
// Conversion to public contact ids
|
||||
array_walk($ids, function (&$contactId) use ($uid, $stringify_ids) {
|
||||
$cdata = Contact::getPublicAndUserContacID($contactId, $uid);
|
||||
$cdata = Contact::getPublicAndUserContactID($contactId, $uid);
|
||||
if ($stringify_ids) {
|
||||
$contactId = (string)$cdata['public'];
|
||||
} else {
|
||||
|
|
|
@ -283,7 +283,7 @@ class Contact extends BaseModule
|
|||
$contact_id = intval($a->argv[1]);
|
||||
|
||||
// Ensure to use the user contact when the public contact was provided
|
||||
$data = Model\Contact::getPublicAndUserContacID($contact_id, local_user());
|
||||
$data = Model\Contact::getPublicAndUserContactID($contact_id, local_user());
|
||||
if (!empty($data['user']) && ($contact_id == $data['public'])) {
|
||||
$contact_id = $data['user'];
|
||||
}
|
||||
|
@ -915,7 +915,7 @@ class Contact extends BaseModule
|
|||
public static function getTabsHTML(array $contact, int $active_tab)
|
||||
{
|
||||
$cid = $pcid = $contact['id'];
|
||||
$data = Model\Contact::getPublicAndUserContacID($contact['id'], local_user());
|
||||
$data = Model\Contact::getPublicAndUserContactID($contact['id'], local_user());
|
||||
if (!empty($data['user']) && ($contact['id'] == $data['public'])) {
|
||||
$cid = $data['user'];
|
||||
} elseif (!empty($data['public'])) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue