]> git.mxchange.org Git - friendica.git/commitdiff
Always generate a random header if missing
authorMichael <heluecht@pirati.ca>
Sun, 9 Jan 2022 11:19:31 +0000 (11:19 +0000)
committerMichael <heluecht@pirati.ca>
Sun, 9 Jan 2022 11:19:31 +0000 (11:19 +0000)
src/Model/Contact.php

index 65ee65ab32aac40b700a83a7b10adf242454845b..9d609786e96a1880ec0c63d0ab31f29fdc587be6 100644 (file)
@@ -1668,8 +1668,8 @@ class Contact
         */
        public static function getDefaultHeader(array $contact): string
        {
-               if (!empty($contact['header']) || in_array($contact['network'], [Protocol::ACTIVITYPUB, Protocol::TWITTER])) {
-                       return DI::baseUrl() . '/images/blank.png';
+               if (!empty($contact['header'])) {
+                       return $contact['header'];
                }
 
                if (!empty($contact['gsid'])) {
@@ -1702,7 +1702,7 @@ class Contact
                                break;
                        default:
                                /**
-                                * Use random pictures for networks that don't provide banners.
+                                * Use a random picture. 
                                 * The service provides random pictures from Unsplash.
                                 * @license https://unsplash.com/license
                                 */