diff options
author | Roeland Jago Douma <roeland@famdouma.nl> | 2016-07-20 21:30:39 +0200 |
---|---|---|
committer | Roeland Jago Douma <roeland@famdouma.nl> | 2016-07-20 22:05:43 +0200 |
commit | e42f2f26504e3fcf975c15c3d3732646e819f37e (patch) | |
tree | 480716a1d52023beb64b39551eb83b4ae217e7a7 /lib/private/AppFramework/Middleware | |
parent | 020a2a6958e48f7a3a29daa2235f6729980850af (diff) | |
download | nextcloud-server-e42f2f26504e3fcf975c15c3d3732646e819f37e.tar.gz nextcloud-server-e42f2f26504e3fcf975c15c3d3732646e819f37e.zip |
AppFramework do not get default response
The OCSResponse differs from other responses in that it defaults to
XML. However we fell back to json by default.
This makes sure that if nothing is set we don't pass anything.
Which defaults then to the controllers default (which is often 'json')
but in the case of the OCSResponse 'xml'.
Diffstat (limited to 'lib/private/AppFramework/Middleware')
-rw-r--r-- | lib/private/AppFramework/Middleware/OCSMiddleware.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/private/AppFramework/Middleware/OCSMiddleware.php b/lib/private/AppFramework/Middleware/OCSMiddleware.php index 2c7d1167e7c..b21e8e05a90 100644 --- a/lib/private/AppFramework/Middleware/OCSMiddleware.php +++ b/lib/private/AppFramework/Middleware/OCSMiddleware.php @@ -72,7 +72,7 @@ class OCSMiddleware extends Middleware { // if none is given try the first Accept header if($format === null) { $headers = $this->request->getHeader('Accept'); - $format = $controller->getResponderByHTTPHeader($headers); + $format = $controller->getResponderByHTTPHeader($headers, 'xml'); } return $format; |