diff options
author | Michael Gapczynski <mtgap@owncloud.com> | 2013-05-17 11:42:14 -0400 |
---|---|---|
committer | Michael Gapczynski <mtgap@owncloud.com> | 2013-05-17 11:42:14 -0400 |
commit | 5368c8dafa0ab10f8ee47940f4ad1a4585023e45 (patch) | |
tree | ad90751b5dbe2228efed62818c997ee427b42bcd /apps/files_external | |
parent | ee398ccbc26c3702537c0c83bd898f326562dd14 (diff) | |
download | nextcloud-server-5368c8dafa0ab10f8ee47940f4ad1a4585023e45.tar.gz nextcloud-server-5368c8dafa0ab10f8ee47940f4ad1a4585023e45.zip |
Prepare for #2013 fix
Diffstat (limited to 'apps/files_external')
-rw-r--r-- | apps/files_external/lib/google.php | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/apps/files_external/lib/google.php b/apps/files_external/lib/google.php index 3f7a9877f78..36b890e82e8 100644 --- a/apps/files_external/lib/google.php +++ b/apps/files_external/lib/google.php @@ -248,7 +248,13 @@ class Google extends \OC\Files\Storage\Common { if ($this->filetype($path) === 'dir') { $stat['size'] = 0; } else { - $stat['size'] = $file->getFileSize(); + // Check if this is a Google Doc + if ($this->getMimeType($path) !== $file->getMimeType()) { + // Return unknown file size + $stat['size'] = \OC\Files\Filesystem::FREE_SPACE_UNKNOWN; + } else { + $stat['size'] = $file->getFileSize(); + } } $stat['atime'] = strtotime($file->getLastViewedByMeDate()); $stat['mtime'] = strtotime($file->getModifiedDate()); |