]> source.dussan.org Git - nextcloud-server.git/commitdiff
Have the OCSBaseResponse call the parent constructor
authorRoeland Jago Douma <roeland@famdouma.nl>
Tue, 30 Jul 2019 08:44:44 +0000 (10:44 +0200)
committerRoeland Jago Douma <roeland@famdouma.nl>
Thu, 8 Aug 2019 07:52:20 +0000 (09:52 +0200)
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
lib/private/AppFramework/OCS/BaseResponse.php

index b27784cfcf2ddd2a651c1cf30643af992dfc63c3..90ea084dd99f1b0553d08387769bfdfaf2b64bfe 100644 (file)
@@ -57,6 +57,8 @@ abstract class BaseResponse extends Response   {
                                                                $statusMessage = null,
                                                                $itemsCount = null,
                                                                $itemsPerPage = null) {
+               parent::__construct();
+
                $this->format = $format;
                $this->statusMessage = $statusMessage;
                $this->itemsCount = $itemsCount;
@@ -69,7 +71,6 @@ abstract class BaseResponse extends Response   {
                $this->setETag($dataResponse->getETag());
                $this->setLastModified($dataResponse->getLastModified());
                $this->setCookies($dataResponse->getCookies());
-               $this->setContentSecurityPolicy(new EmptyContentSecurityPolicy());
 
                if ($format === 'json') {
                        $this->addHeader(