diff --git a/lib/public/appframework/http/redirectresponse.php b/lib/public/appframework/http/redirectresponse.php index 7208012295fe..bb0c8843715e 100644 --- a/lib/public/appframework/http/redirectresponse.php +++ b/lib/public/appframework/http/redirectresponse.php @@ -44,7 +44,7 @@ class RedirectResponse extends Response { */ public function __construct($redirectURL) { $this->redirectURL = $redirectURL; - $this->setStatus(Http::STATUS_TEMPORARY_REDIRECT); + $this->setStatus(Http::STATUS_SEE_OTHER); $this->addHeader('Location', $redirectURL); } diff --git a/tests/lib/appframework/http/RedirectResponseTest.php b/tests/lib/appframework/http/RedirectResponseTest.php index 17db0c0be6cc..723f6600c559 100644 --- a/tests/lib/appframework/http/RedirectResponseTest.php +++ b/tests/lib/appframework/http/RedirectResponseTest.php @@ -43,7 +43,7 @@ protected function setUp(){ public function testHeaders() { $headers = $this->response->getHeaders(); $this->assertEquals('/url', $headers['Location']); - $this->assertEquals(Http::STATUS_TEMPORARY_REDIRECT, + $this->assertEquals(Http::STATUS_SEE_OTHER, $this->response->getStatus()); }