diff options
author | Frank Karlitschek <frank@owncloud.org> | 2013-02-19 15:18:12 -0800 |
---|---|---|
committer | Frank Karlitschek <frank@owncloud.org> | 2013-02-19 15:18:12 -0800 |
commit | 38782036798dbe0a34995a3fca0aa92583cb9099 (patch) | |
tree | a999e79775f1e539ff9fb0d55e346721b4b0740d /lib/files | |
parent | 99758dce2b9e014081c27ff35b1df9e16f9eb430 (diff) | |
parent | 451daf3ab14edde76f4d04e6fe41519cf517fe47 (diff) | |
download | nextcloud-server-38782036798dbe0a34995a3fca0aa92583cb9099.tar.gz nextcloud-server-38782036798dbe0a34995a3fca0aa92583cb9099.zip |
Merge pull request #1731 from owncloud/unknown-freespace
Give storage backends the option to define having no known free space
Diffstat (limited to 'lib/files')
-rw-r--r-- | lib/files/filesystem.php | 2 | ||||
-rw-r--r-- | lib/files/storage/common.php | 9 |
2 files changed, 11 insertions, 0 deletions
diff --git a/lib/files/filesystem.php b/lib/files/filesystem.php index cba469e06c4..875a9d6c5ee 100644 --- a/lib/files/filesystem.php +++ b/lib/files/filesystem.php @@ -29,6 +29,8 @@ namespace OC\Files; +const FREE_SPACE_UNKNOWN = -2; + class Filesystem { public static $loaded = false; /** diff --git a/lib/files/storage/common.php b/lib/files/storage/common.php index 4cdabf1c8a6..4e7a73e5d4a 100644 --- a/lib/files/storage/common.php +++ b/lib/files/storage/common.php @@ -301,4 +301,13 @@ abstract class Common implements \OC\Files\Storage\Storage { } return implode('/', $output); } + + /** + * get the free space in the storage + * @param $path + * return int + */ + public function free_space($path){ + return \OC\Files\FREE_SPACE_UNKNOWN; + } } |