Allow getting filesize by function

This commit is contained in:
Mikael Nordfeldth 2016-06-24 15:53:23 +02:00
parent f1e3314bb7
commit 1dfac3ad63

View File

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