From b9aa474eb3d735a8d32b1bc2f28006856c020b11 Mon Sep 17 00:00:00 2001 From: danielmaya Date: Mon, 10 Dec 2018 15:14:56 +0100 Subject: [PATCH] Fixed sql error with empty array in agent view Former-commit-id: 5a7655d97d28179793a9c029460837568f926128 --- pandora_console/include/functions_tags.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/pandora_console/include/functions_tags.php b/pandora_console/include/functions_tags.php index fb339f1886..b6c7647562 100644 --- a/pandora_console/include/functions_tags.php +++ b/pandora_console/include/functions_tags.php @@ -808,8 +808,11 @@ function tags_get_acl_tags_event_condition($acltags, $meta = false, $force_group $tags_condition = $group_condition . " AND (" . implode(" OR ", $tags_condition_array) . ")"; $condition[] = "($tags_condition)\n"; } + if (!empty($condition)) { $condition = implode(' OR ', $condition); + } else { + $condition = ''; } if (!empty($without_tags)) {