From 7e3298753a9f93405ef44b46ba4db4ca98553b51 Mon Sep 17 00:00:00 2001 From: Aleksander Machniak <alec@alec.pl> Date: Sat, 14 Nov 2015 04:08:07 -0500 Subject: [PATCH] Use ternary operator where aplicable --- program/steps/utils/error.inc | 11 ++++++++++- 1 files changed, 10 insertions(+), 1 deletions(-) diff --git a/program/steps/utils/error.inc b/program/steps/utils/error.inc index 16fbb03..7ca933e 100644 --- a/program/steps/utils/error.inc +++ b/program/steps/utils/error.inc @@ -1,6 +1,6 @@ <?php -/* +/** +-----------------------------------------------------------------------+ | program/steps/utils/error.inc | | | @@ -72,6 +72,15 @@ $__error_text .= '<p><i>' . $rcmail->gettext('errfailedrequest') . ":</i><br />\n<tt>//$request_url</tt></p>"; } +// invalid compose ID +else if ($ERROR_CODE == 450 && $_SERVER['REQUEST_METHOD'] == 'GET' && $rcmail->action == 'compose') { + $url = $rcmail->url('compose'); + + $__error_title = strtoupper($rcmail->gettext('errcomposesession')); + $__error_text = nl2br($rcmail->gettext('errcomposesessionexplain')) + . '<p>' . html::a($url, $rcmail->gettext('clicktocompose')) . '</p>'; +} + // database connection error else if ($ERROR_CODE == 601) { $__error_title = "CONFIGURATION ERROR"; -- Gitblit v1.9.1