From 88c4e57fb50c94f1bbb85a746516a8b30635479c Mon Sep 17 00:00:00 2001 From: hickert Date: Tue, 3 Feb 2009 11:07:44 +0000 Subject: [PATCH] Updated gosa log view, fixed undefined index,. git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@13377 594d385d-05f5-0310-b6e9-bd551577e9d8 --- .../log/addons/logview/class_gosa_logview.inc | 28 ++++++++++--------- 1 file changed, 15 insertions(+), 13 deletions(-) diff --git a/gosa-plugins/log/addons/logview/class_gosa_logview.inc b/gosa-plugins/log/addons/logview/class_gosa_logview.inc index 794ab8af8..0c6b0e515 100644 --- a/gosa-plugins/log/addons/logview/class_gosa_logview.inc +++ b/gosa-plugins/log/addons/logview/class_gosa_logview.inc @@ -110,19 +110,21 @@ class gosa_logview extends plugin $smarty->assign("$type", $this->$type); } - /**** - * Check if defined servers - * and mysql extension - ****/ - if (!isset($this->config->data['SERVERS']['LOGGING']) || !count($this->config->data['SERVERS']['LOGGING'])){ - msg_dialog::display(_("Warning"), msgPool::noserver("GOsa log"), WARNING_DIALOG); - return ($smarty->fetch (get_template_path('gosa_log_contents.tpl', TRUE))); - } - - if(!is_callable("mysql_connect")){ - msg_dialog::display(_("Configuration error"), sprintf(_("Missing %s PHP extension!"), "mysql"), WARNING_DIALOG); - return ($smarty->fetch (get_template_path('gosa_log_contents.tpl', TRUE))); - } + /**** + * Check if defined servers + * and mysql extension + ****/ + if (!isset($this->config->data['SERVERS']['LOGGING']) || !count($this->config->data['SERVERS']['LOGGING'])){ + msg_dialog::display(_("Warning"), msgPool::noserver("GOsa log"), WARNING_DIALOG); + $smarty->assign("servers", array()); + return ($smarty->fetch (get_template_path('gosa_log_contents.tpl', TRUE))); + } + + if(!is_callable("mysql_connect")){ + msg_dialog::display(_("Configuration error"), sprintf(_("Missing %s PHP extension!"), "mysql"), WARNING_DIALOG); + $smarty->assign("servers", array()); + return ($smarty->fetch (get_template_path('gosa_log_contents.tpl', TRUE))); + } /**** * Get Configurations -- 2.30.2