]> git.mxchange.org Git - friendica.git/blobdiff - mod/wall_upload.php
Docs: add a note on adding `use` on theme.php
[friendica.git] / mod / wall_upload.php
index 821fdc2a958a7564904f448330095a248dc44393..61578ca5c8204e334b7b86728b671c0660472840 100644 (file)
@@ -114,7 +114,10 @@ function wall_upload_post(App $a, $desktopmode = true) {
                killme();
        }
 
-       $src = "";
+       $src = '';
+       $filename = '';
+       $filesize = 0;
+       $filetype = '';
        if (x($_FILES, 'userfile')) {
                $src      = $_FILES['userfile']['tmp_name'];
                $filename = basename($_FILES['userfile']['name']);
@@ -219,7 +222,7 @@ function wall_upload_post(App $a, $desktopmode = true) {
        $width = $Image->getWidth();
        $height = $Image->getHeight();
 
-       $hash = photo_new_resource();
+       $hash = Photo::newResource();
 
        $smallest = 0;