diff options
Diffstat (limited to 'lib/public/AppFramework')
-rw-r--r-- | lib/public/AppFramework/Http/NotFoundResponse.php | 15 |
1 files changed, 2 insertions, 13 deletions
diff --git a/lib/public/AppFramework/Http/NotFoundResponse.php b/lib/public/AppFramework/Http/NotFoundResponse.php index ffebfdf3c76..9bf08443a89 100644 --- a/lib/public/AppFramework/Http/NotFoundResponse.php +++ b/lib/public/AppFramework/Http/NotFoundResponse.php @@ -24,30 +24,19 @@ namespace OCP\AppFramework\Http; -use OCP\Template; - /** * A generic 404 response showing an 404 error page as well to the end-user * @since 8.1.0 */ -class NotFoundResponse extends Response { +class NotFoundResponse extends TemplateResponse { /** * @since 8.1.0 */ public function __construct() { - parent::__construct(); + parent::__construct('core', '404', [], 'guest'); $this->setContentSecurityPolicy(new ContentSecurityPolicy()); $this->setStatus(404); } - - /** - * @return string - * @since 8.1.0 - */ - public function render() { - $template = new Template('core', '404', 'guest'); - return $template->fetchPage(); - } } |