Merge pull request #12242 from owncloud/fix-undefined-size

Check if the size field is available
This commit is contained in:
Lukas Reschke 2014-11-18 12:37:16 +01:00
commit 8d4e63dd7c
1 changed files with 1 additions and 1 deletions

View File

@ -122,7 +122,7 @@ class FileInfo implements \OCP\Files\FileInfo, \ArrayAccess {
* @return int
*/
public function getSize() {
return $this->data['size'];
return isset($this->data['size']) ? $this->data['size'] : 0;
}
/**