[Pkg-owncloud-commits] [php-sabredav] 64/66: Fix for getQuotaInfo on windows.
David Prévot
taffit at moszumanska.debian.org
Wed May 27 13:56:59 UTC 2015
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to tag 3.0.0-alpha1
in repository php-sabredav.
commit 34dfdfe1a42ca497c3904961c29c4d2d4f98ae71
Author: Evert Pot <me at evertpot.com>
Date: Tue May 19 13:54:13 2015 +0300
Fix for getQuotaInfo on windows.
Fixes #193.
---
CHANGELOG.md | 2 +-
lib/DAV/FSExt/Directory.php | 8 +++++---
2 files changed, 6 insertions(+), 4 deletions(-)
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 762e9d4..fba2b08 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -98,7 +98,7 @@ ChangeLog
to the latest API!
* #582: `Sabre\DAV\Auth\Plugin::getCurrentUser()` is now deprecated. Use
`Sabre\DAV\Auth\Plugin::getCurrentPrincipal()` instead.
-
+* #193: Fix `Sabre\DAV\FSExt\Directory::getQuotaInfo()` on windows.
2.1.4 (2015-??-??)
------------------
diff --git a/lib/DAV/FSExt/Directory.php b/lib/DAV/FSExt/Directory.php
index e9a1843..60013af 100644
--- a/lib/DAV/FSExt/Directory.php
+++ b/lib/DAV/FSExt/Directory.php
@@ -170,11 +170,13 @@ class Directory extends Node implements DAV\ICollection, DAV\IQuota, DAV\IMoveTa
*/
function getQuotaInfo() {
+ $total = disk_total_space(realpath($this->path));
+ $free = disk_free_space(realpath($this->path));
+
return [
- disk_total_space($this->path)-disk_free_space($this->path),
- disk_free_space($this->path)
+ $total - $free,
+ $free
];
-
}
/**
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-owncloud/php-sabredav.git
More information about the Pkg-owncloud-commits
mailing list