]> git.mxchange.org Git - friendica.git/blobdiff - src/Model/User.php
Improve accuracy of User::getList with type = blocked
[friendica.git] / src / Model / User.php
index e6f20f738732d32524ced00a71f615224a5cc1a5..39f9dc2a15109530f8892e68cdc6d39f8a0c7766 100644 (file)
@@ -1002,16 +1002,16 @@ class User
                        $photo_failure = false;
 
                        $filename = basename($photo);
-                       $curlResult = DI::httpRequest()->get($photo, true);
+                       $curlResult = DI::httpRequest()->get($photo);
                        if ($curlResult->isSuccess()) {
                                $img_str = $curlResult->getBody();
-                               $contType = $curlResult->getContentType();
+                               $type = $curlResult->getContentType();
                        } else {
                                $img_str = '';
-                               $contType = '';
+                               $type = '';
                        }
 
-                       $type = Images::getMimeTypeByData($img_str, $photo, $contType);
+                       $type = Images::getMimeTypeByData($img_str, $photo, $type);
 
                        $Image = new Image($img_str, $type);
                        if ($Image->isValid()) {
@@ -1511,7 +1511,9 @@ class User
                                $condition['blocked'] = false;
                                break;
                        case 'blocked':
+                               $condition['account_removed'] = false;
                                $condition['blocked'] = true;
+                               $condition['verified'] = true;
                                break;
                        case 'removed':
                                $condition['account_removed'] = true;