[Pkg-owncloud-commits] [php-sabredav] 16/80: A better error message when the browser plugin is not enabled.
David Prévot
taffit at moszumanska.debian.org
Thu Jan 7 02:56:17 UTC 2016
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to branch master
in repository php-sabredav.
commit e09b67f2e66b51436bd5902a145db1b85e7d8ae7
Author: Evert Pot <me at evertpot.com>
Date: Sat Oct 17 17:16:14 2015 -0400
A better error message when the browser plugin is not enabled.
---
CHANGELOG.md | 6 ++++++
lib/DAV/Server.php | 7 ++++++-
2 files changed, 12 insertions(+), 1 deletion(-)
diff --git a/CHANGELOG.md b/CHANGELOG.md
index f2f989c..e6289cb 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,6 +1,12 @@
ChangeLog
=========
+3.1.0-alpha3 (2015-??-??)
+-------------------------
+
+* Better error message when the browser plugin is not enabled.
+
+
3.1.0-alpha2 (2015-09-05)
-------------------------
diff --git a/lib/DAV/Server.php b/lib/DAV/Server.php
index e68af5a..7d3a3de 100644
--- a/lib/DAV/Server.php
+++ b/lib/DAV/Server.php
@@ -458,8 +458,13 @@ class Server extends EventEmitter {
if ($this->emit('method:' . $method, [$request, $response])) {
if ($this->emit('method', [$request, $response])) {
+ $exMessage = "There was no plugin in the system that was willing to handle this " . $method . " method.";
+ if ($method === "GET") {
+ $exMessage .= " Enable the Browser plugin to get a better result here.";
+ }
+
// Unsupported method
- throw new Exception\NotImplemented('There was no handler found for this "' . $method . '" method');
+ throw new Exception\NotImplemented($exMessage);
}
}
--
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