From d2e5508023052562516f3e8526814609bda4d90f Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Mon, 28 Jun 2010 08:09:11 +0000 Subject: [PATCH] Better handling of errors --- inc/functions.php | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/inc/functions.php b/inc/functions.php index 476927420c..ab3c7099da 100644 --- a/inc/functions.php +++ b/inc/functions.php @@ -3581,7 +3581,13 @@ function flushTemplateCache ($template, $eval) { // Reads a template cache function readTemplateCache ($template) { // Check it again - if ((isDebuggingTemplateCache() === false) && (isTemplateCached($template))) { + if ((isDebuggingTemplateCache()) || (!isTemplateCached($template))) { + // This should not happen + debug_report_bug('Wether debugging of template cache is enabled or template ' . $template . ' is not cached while expected.'); + } // END - if + + // Is it cached? + if (!isset($GLOBALS['template_eval'][$template])) { // Generate FQFN $FQFN = generateCacheFqfn($template); -- 2.39.5