]> git.mxchange.org Git - friendica-addons.git/commitdiff
Images::getInfoFromURL[Cached]() will both return empty arrays on error and that...
authorRoland Häder <roland@mxchange.org>
Wed, 22 Jun 2022 15:19:26 +0000 (17:19 +0200)
committerRoland Häder <roland@mxchange.org>
Wed, 22 Jun 2022 15:20:11 +0000 (17:20 +0200)
statusnet/statusnet.php
twitter/twitter.php

index 6fc1469c243843d1566abefb77338c4c6f3cb86a..f0f2755b59a41aee4001e4022502a9b0b0f066be 100644 (file)
@@ -1050,7 +1050,7 @@ function statusnet_createpost(App $a, $uid, $post, $self, $create_user, $only_ex
                $own_url = DI::pConfig()->get($uid, 'statusnet', 'own_url');
 
                if ($content->user->id == $own_url) {
-                       $self = DBA::selectFirst([], ['self' => true, 'uid' => $uid]);
+                       $self = DBA::selectFirst('', ['self' => true, 'uid' => $uid]);
                        if (DBA::isResult($self)) {
                                $contactid = $self["id"];
 
index 3c46ac7e4a2c2233bf46759b93ab83be48f8579b..5a5071fc75952f0dd59bc5038022fdfad7b3245f 100644 (file)
@@ -1279,7 +1279,7 @@ function twitter_fix_avatar($avatar)
        $new_avatar = str_replace("_normal.", "_400x400.", $avatar);
 
        $info = Images::getInfoFromURLCached($new_avatar);
-       if (!$info) {
+       if (empty($info)) {
                $new_avatar = $avatar;
        }