From 1d8700d4f2e7e5a7a17267de4c98908eb50e9ea2 Mon Sep 17 00:00:00 2001 From: mdtrooper Date: Tue, 4 May 2010 11:06:59 +0000 Subject: [PATCH] 2010-05-04 Miguel de Dios * include/functions_reporting.php: fixed in the function "get_agentmodule_data_average" prevent to use the var without value. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@2662 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f --- pandora_console/ChangeLog | 5 +++++ pandora_console/include/functions_reporting.php | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/pandora_console/ChangeLog b/pandora_console/ChangeLog index abea6a7c4a..52d0d3225e 100644 --- a/pandora_console/ChangeLog +++ b/pandora_console/ChangeLog @@ -1,3 +1,8 @@ +2010-05-04 Miguel de Dios + + * include/functions_reporting.php: fixed in the function + "get_agentmodule_data_average" prevent to use the var without value. + 2010-05-04 Sergio Martin * include/functions_reporting.php: Added the diff --git a/pandora_console/include/functions_reporting.php b/pandora_console/include/functions_reporting.php index 0085ce02a2..2a3d611314 100644 --- a/pandora_console/include/functions_reporting.php +++ b/pandora_console/include/functions_reporting.php @@ -59,7 +59,7 @@ function get_agentmodule_data_average ($id_agent_module, $period, $date = 0) { $total = 0; $module_interval = get_module_interval ($id_agent_module); $previous_data = get_previous_data ($id_agent_module, $datelimit); - if ($previous_data !== false) { + if (($previous_data !== false) && (isset($interval_data))) { array_unshift ($interval_data, $values); }