From 40975184e0fff7e667cdfb83940ff2a77581dd0f Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Wed, 15 Nov 2023 20:32:49 -0500 Subject: [PATCH] Return the found term instead of true in has_term. --- web/includes/Filter.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web/includes/Filter.php b/web/includes/Filter.php index f813ced02..94dfafb17 100644 --- a/web/includes/Filter.php +++ b/web/includes/Filter.php @@ -1259,7 +1259,7 @@ class Filter extends ZM_Object { public function has_term($attr, $op=null) { foreach ($this->terms() as $term) { - if (($term['attr'] == $attr) and ((!$op) or ($term['op']==$op)) ) return true; + if (($term['attr'] == $attr) and ((!$op) or ($term['op']==$op)) ) return $term; } return false; }