]> git.mxchange.org Git - friendica.git/blobdiff - src/Object/Image.php
Continued:
[friendica.git] / src / Object / Image.php
index d8d6dafc3ca86d60bfbe180f6ad2e8f290cddac3..9692b84715c1d0e47db33de116c2e72ddd248a02 100644 (file)
@@ -771,6 +771,10 @@ class Image
        {
                $data = [];
 
+               if (empty($url)) {
+                       return $data;
+               }
+
                $data = Cache::get($url);
 
                if (is_null($data) || !$data || !is_array($data)) {
@@ -937,7 +941,7 @@ class Image
                $width = $Image->getWidth();
                $height = $Image->getHeight();
 
-               $hash = photo_new_resource();
+               $hash = Photo::newResource();
 
                $smallest = 0;