]> git.mxchange.org Git - friendica.git/commitdiff
Tests ...
authorMichael <heluecht@pirati.ca>
Sun, 21 Nov 2021 00:14:38 +0000 (00:14 +0000)
committerMichael <heluecht@pirati.ca>
Sun, 21 Nov 2021 00:14:38 +0000 (00:14 +0000)
src/Factory/Api/Twitter/User.php
tests/legacy/ApiTest.php

index e545bd78cbdf40a9cb6d37496550348a89674371..c502e3830a9dcffb81eecbdbc4592dbf5608f598 100644 (file)
@@ -48,6 +48,10 @@ class User extends BaseFactory
                        $userContact = [];
                }
 
+               if (empty($publicContact)) {
+                       return null;
+               }
+
                $apcontact = APContact::getByURL($publicContact['url'], false);
 
                return new \Friendica\Object\Api\Twitter\User($publicContact, $apcontact, $userContact, $skip_status, $include_user_entities);
index a64ffbf914a604c6556917264096a416332afe49..8e5743facb2f49de5ce0110dc6053b664b3e0089 100644 (file)
@@ -2234,6 +2234,7 @@ class ApiTest extends FixtureTest
                                'author-network' => Protocol::DFRN,
                                'author-link'    => 'http://localhost/profile/othercontact',
                                'plink'          => '',
+                               'uid'            => $this->selfUser['id'],
                        ]
                ];
                foreach ($items as $item) {
@@ -2257,6 +2258,7 @@ class ApiTest extends FixtureTest
                                'author-network' => Protocol::DFRN,
                                'author-link'    => 'http://localhost/profile/othercontact',
                                'plink'          => '',
+                               'uid'            => $this->selfUser['id'],
                        ]
                ];