mirror of
https://github.com/nextcloud/server.git
synced 2026-04-29 01:50:33 -04:00
Merge pull request #49851 from nextcloud/backport/49839/stable30
[stable30] fix: return 204 instead of 404
This commit is contained in:
commit
828594cdd4
2 changed files with 2 additions and 2 deletions
|
|
@ -91,7 +91,7 @@ class ImageExportPlugin extends ServerPlugin {
|
|||
|
||||
$response->setBody($file->getContent());
|
||||
} catch (NotFoundException $e) {
|
||||
$response->setStatus(404);
|
||||
$response->setStatus(\OCP\AppFramework\Http::STATUS_NO_CONTENT);
|
||||
}
|
||||
|
||||
return false;
|
||||
|
|
|
|||
|
|
@ -171,7 +171,7 @@ class ImageExportPluginTest extends TestCase {
|
|||
->willThrowException(new NotFoundException());
|
||||
$this->response->expects($this->once())
|
||||
->method('setStatus')
|
||||
->with(404);
|
||||
->with(\OCP\AppFramework\Http::STATUS_NO_CONTENT);
|
||||
}
|
||||
|
||||
$result = $this->plugin->httpGet($this->request, $this->response);
|
||||
|
|
|
|||
Loading…
Reference in a new issue