]> git.mxchange.org Git - friendica.git/blobdiff - include/plaintext.php
Separate Object\Photo into Model\Photo and Object\Image
[friendica.git] / include / plaintext.php
index 221d1471b1a7576fd8199e42108027037abf43d1..39dcc9ecdbd7d888cdc6c601bde0acc3570a4dd9 100644 (file)
@@ -5,7 +5,7 @@
 use Friendica\App;
 use Friendica\ParseUrl;
 use Friendica\Core\PConfig;
-use Friendica\Object\Photo;
+use Friendica\Object\Image;
 
 require_once "include/bbcode.php";
 require_once "include/html2plain.php";
@@ -51,7 +51,7 @@ function get_old_attachment_data($body) {
 
                        if (preg_match("/\[img\]([$URLSearchString]*)\[\/img\]/ism", $attacheddata, $matches)) {
 
-                               $picturedata = Photo::getInfoFromURL($matches[1]);
+                               $picturedata = Image::getInfoFromURL($matches[1]);
 
                                if (($picturedata[0] >= 500) && ($picturedata[0] >= $picturedata[1]))
                                        $post["image"] = $matches[1];
@@ -221,7 +221,7 @@ function get_attached_data($body, $item = array()) {
                                        $post["preview"] = $pictures[0][2];
                                        $post["text"] = str_replace($pictures[0][0], "", $body);
                                } else {
-                                       $imgdata = Photo::getInfoFromURL($pictures[0][1]);
+                                       $imgdata = Image::getInfoFromURL($pictures[0][1]);
                                        if (substr($imgdata["mime"], 0, 6) == "image/") {
                                                $post["type"] = "photo";
                                                $post["image"] = $pictures[0][1];