From 885494786658a3f4a7402d0cb7812787251e9ba7 Mon Sep 17 00:00:00 2001 From: Sven Slootweg Date: Sat, 10 May 2014 02:52:27 +0200 Subject: [PATCH] Display a regular 404 error when a project does not exist --- public_html/authenticators/project.php | 2 +- public_html/modules/error/project.php | 17 ----------------- public_html/rewrite.php | 2 +- public_html/templates/error/project.tpl | 3 --- 4 files changed, 2 insertions(+), 22 deletions(-) delete mode 100644 public_html/modules/error/project.php delete mode 100644 public_html/templates/error/project.tpl diff --git a/public_html/authenticators/project.php b/public_html/authenticators/project.php index 961e980..e4ae868 100644 --- a/public_html/authenticators/project.php +++ b/public_html/authenticators/project.php @@ -24,5 +24,5 @@ try } catch (NotFoundException $e) { - $sRouterAuthenticated = false; + throw new RouterException("Project does not exist"); } diff --git a/public_html/modules/error/project.php b/public_html/modules/error/project.php deleted file mode 100644 index e3a9600..0000000 --- a/public_html/modules/error/project.php +++ /dev/null @@ -1,17 +0,0 @@ -strings, array()); -$router->uVariables['page_type'] = ""; diff --git a/public_html/rewrite.php b/public_html/rewrite.php index 9c12a1c..5d96376 100644 --- a/public_html/rewrite.php +++ b/public_html/rewrite.php @@ -39,7 +39,7 @@ $presets = array( "project" => array( "_page_type" => "project", "authenticator" => "authenticators/project.php", - "auth_error" => "modules/error/project.php" + "auth_error" => "" ) ); diff --git a/public_html/templates/error/project.tpl b/public_html/templates/error/project.tpl deleted file mode 100644 index 536c998..0000000 --- a/public_html/templates/error/project.tpl +++ /dev/null @@ -1,3 +0,0 @@ -
- The project you are looking for does not appear to exist. -