]> git.mxchange.org Git - friendica.git/blobdiff - src/Contact/Avatar.php
Introduce new Hook logic
[friendica.git] / src / Contact / Avatar.php
index 7151acbfbd0190a6bb9bf8e63d1cce97f8f88503..e039a52799fc524e98f605cbb00ad51e198307a1 100644 (file)
@@ -246,13 +246,16 @@ class Avatar
         * Delete locally cached avatar pictures of a contact
         *
         * @param string $avatar
-        * @return void
+        * @return bool
         */
-       public static function deleteCache(array $contact)
+       public static function deleteCache(array $contact): bool
        {
+               $existed = (self::isCacheFile($contact['photo']) || self::isCacheFile($contact['thumb']) || self::isCacheFile($contact['micro']));
                self::deleteCacheFile($contact['photo']);
                self::deleteCacheFile($contact['thumb']);
                self::deleteCacheFile($contact['micro']);
+
+               return $existed;
        }
 
        /**