]> git.mxchange.org Git - friendica.git/blobdiff - src/Util/Images.php
messages.po and and corrected typo in comment
[friendica.git] / src / Util / Images.php
index 533feec844f62ddf75b83a006cae49daf7fe31e1..a6a9f4f7db78f66255bf86f9dbf457521742afa6 100644 (file)
@@ -247,8 +247,11 @@ class Images
                if ($data) {
                        $image = new Image($img_str);
 
-                       $data['blurhash'] = $image->getBlurHash();
-                       $data['size']     = $filesize;
+                       if ($image->isValid()) {
+                               $data['blurhash'] = $image->getBlurHash();
+                       }
+
+                       $data['size'] = $filesize;
                }
 
                return is_array($data) ? $data : [];