diff --git a/lib/Middleware/JoinMiddleware.php b/lib/Middleware/JoinMiddleware.php index d6fde36..5a33d47 100644 --- a/lib/Middleware/JoinMiddleware.php +++ b/lib/Middleware/JoinMiddleware.php @@ -6,8 +6,8 @@ use OCA\BigBlueButton\Controller\JoinController; use OCA\BigBlueButton\NoPermissionException; use OCA\BigBlueButton\NoPermissionResponse; use OCA\BigBlueButton\NotFoundException; +use OCA\BigBlueButton\NotFoundResponse; use OCP\AppFramework\Middleware; -use OCP\AppFramework\Http\NotFoundResponse; use OCP\IRequest; class JoinMiddleware extends Middleware { diff --git a/lib/NotFoundResponse.php b/lib/NotFoundResponse.php new file mode 100644 index 0000000..b3e42dd --- /dev/null +++ b/lib/NotFoundResponse.php @@ -0,0 +1,21 @@ +setContentSecurityPolicy(new ContentSecurityPolicy()); + $this->setStatus(404); + } + + public function render() { + $template = new Template('bbb', '404', 'guest'); + return $template->fetchPage(); + } +} diff --git a/templates/404.php b/templates/404.php new file mode 100644 index 0000000..2840403 --- /dev/null +++ b/templates/404.php @@ -0,0 +1,13 @@ + +
t('The room could not be found. Maybe it was deleted?')); ?>
+ +