Browse Source
Allow page reload on /not-found page
Signed-off-by: Joas Schilling <coding@schilljs.com>
pull/3056/head
Joas Schilling
6 years ago
No known key found for this signature in database
GPG Key ID: 7076EA9751AACDDA
2 changed files with
15 additions and
0 deletions
-
appinfo/routes.php
-
lib/Controller/PageController.php
|
|
|
@ -28,6 +28,11 @@ return [ |
|
|
|
'url' => '/', |
|
|
|
'verb' => 'GET', |
|
|
|
], |
|
|
|
[ |
|
|
|
'name' => 'Page#notFound', |
|
|
|
'url' => '/not-found', |
|
|
|
'verb' => 'GET', |
|
|
|
], |
|
|
|
], |
|
|
|
'ocs' => [ |
|
|
|
/** |
|
|
|
|
|
|
|
@ -134,6 +134,16 @@ class PageController extends Controller { |
|
|
|
return $this->index($token, '', $password); |
|
|
|
} |
|
|
|
|
|
|
|
/** |
|
|
|
* @PublicPage |
|
|
|
* @NoCSRFRequired |
|
|
|
* |
|
|
|
* @return Response |
|
|
|
*/ |
|
|
|
public function notFound(): Response { |
|
|
|
return new RedirectResponse($this->url->linkToRouteAbsolute('spreed.Page.index')); |
|
|
|
} |
|
|
|
|
|
|
|
/** |
|
|
|
* @PublicPage |
|
|
|
* @NoCSRFRequired |
|
|
|
|