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
|
@ -60,7 +60,7 @@ class Account extends BaseFactory
|
|||
*/
|
||||
public function createFromContactId(int $contactId, $uid = 0): \Friendica\Object\Api\Mastodon\Account
|
||||
{
|
||||
$cdata = Contact::getPublicAndUserContacID($contactId, $uid);
|
||||
$cdata = Contact::getPublicAndUserContactID($contactId, $uid);
|
||||
if (!empty($cdata)) {
|
||||
$publicContact = Contact::getById($cdata['public']);
|
||||
$userContact = Contact::getById($cdata['user']);
|
||||
|
|
|
@ -49,7 +49,7 @@ class FollowRequest extends BaseFactory
|
|||
*/
|
||||
public function createFromIntroduction(Introduction $introduction): \Friendica\Object\Api\Mastodon\FollowRequest
|
||||
{
|
||||
$cdata = Contact::getPublicAndUserContacID($introduction->{'contact-id'}, $introduction->uid);
|
||||
$cdata = Contact::getPublicAndUserContactID($introduction->{'contact-id'}, $introduction->uid);
|
||||
|
||||
if (empty($cdata)) {
|
||||
$this->logger->warning('Wrong introduction data', ['Introduction' => $introduction]);
|
||||
|
|
|
@ -36,7 +36,7 @@ class Relationship extends BaseFactory
|
|||
*/
|
||||
public function createFromContactId(int $contactId, int $uid): RelationshipEntity
|
||||
{
|
||||
$cdata = Contact::getPublicAndUserContacID($contactId, $uid);
|
||||
$cdata = Contact::getPublicAndUserContactID($contactId, $uid);
|
||||
if (!empty($cdata)) {
|
||||
$cid = $cdata['user'];
|
||||
} else {
|
||||
|
|
|
@ -39,7 +39,7 @@ class User extends BaseFactory
|
|||
*/
|
||||
public function createFromContactId(int $contactId, $uid = 0, $skip_status = false, $include_user_entities = true)
|
||||
{
|
||||
$cdata = Contact::getPublicAndUserContacID($contactId, $uid);
|
||||
$cdata = Contact::getPublicAndUserContactID($contactId, $uid);
|
||||
if (!empty($cdata)) {
|
||||
$publicContact = Contact::getById($cdata['public']);
|
||||
$userContact = Contact::getById($cdata['user']);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue