Monkeys are hard at work to find it for you!
Or you could try on your own.
diff --git a/Changelog b/Changelog index 83166e381..8171b6c01 100755 --- a/Changelog +++ b/Changelog @@ -1,4 +1,5 @@ 2017-08-30 DariusIII + * Chg: Update warnings and http response templates * Chg: Disable caching for php-tmdb * Chg: Update Tmux class, use Models/Tmux and change usage of $pdo variable * Chg: Update bytesToSizeString function in Utility class diff --git a/public/pages/BasePage.php b/public/pages/BasePage.php index 3abf9b813..78bbe6286 100644 --- a/public/pages/BasePage.php +++ b/public/pages/BasePage.php @@ -211,12 +211,7 @@ class BasePage public function showFloodWarning($seconds = 5): void { header('Retry-After: ' . $seconds); - $this->show503( - sprintf( - 'Too many requests!
You must wait %s seconds before trying again.', - $seconds - ) - ); + $this->show503(); } /** @@ -291,6 +286,15 @@ class BasePage die(view('errors.maintenance')); } + /** + * Show Security token mismatch page. + */ + public function showTokenError(): void + { + header('HTTP/1.1 503 Service Temporarily Unavailable'); + die(view('errors.tokenError')); + } + /** * @param string $retry */ diff --git a/public/pages/login.php b/public/pages/login.php index 864565c46..f4eb01dba 100644 --- a/public/pages/login.php +++ b/public/pages/login.php @@ -41,7 +41,7 @@ if (!isset($_POST['username']) || !isset($_POST['password'])) { $logging->LogBadPasswd($username, $_SERVER['REMOTE_ADDR']); } } else { - $page->show503('Security token mismatch!'); + $page->showTokenError(); } } diff --git a/public/pages/register.php b/public/pages/register.php index 30aa51e51..e68e729e4 100644 --- a/public/pages/register.php +++ b/public/pages/register.php @@ -84,7 +84,7 @@ if ($showRegister === 1) { } } } else { - $page->show503('Security token mismatch'); + $page->showTokenError(); } } break; diff --git a/resources/views/errors/404.blade.php b/resources/views/errors/404.blade.php index eead42205..0f4ed944b 100644 --- a/resources/views/errors/404.blade.php +++ b/resources/views/errors/404.blade.php @@ -1,43 +1,9 @@ - - -
-