]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
Allow getting filesize by function
authorMikael Nordfeldth <mmn@hethane.se>
Fri, 24 Jun 2016 13:53:23 +0000 (15:53 +0200)
committerMikael Nordfeldth <mmn@hethane.se>
Fri, 24 Jun 2016 13:53:23 +0000 (15:53 +0200)
classes/File.php

index c85d919fd742e918e29e75a1dc4012bc28be86b1..1a38aefa7243d5e78aae5c3396197c7b1901e15b 100644 (file)
@@ -263,6 +263,11 @@ class File extends Managed_DataObject
         return self::tryFilename($this->filename);
     }
 
+    public function getSize()
+    {
+        return intval($this->size);
+    }
+
     // where should the file go?
 
     static function filename(Profile $profile, $origname, $mimetype)