From f2ceda5aa7ffabc9e1243a32eb16bc69d7f4a76f Mon Sep 17 00:00:00 2001 From: Peter Rotich <peter@osticket.com> Date: Fri, 5 Oct 2012 19:01:50 -0400 Subject: [PATCH] Clear short_list using null to allow for isset use in memoized matches test. --- include/class.filter.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/class.filter.php b/include/class.filter.php index 8a24e8cd3..9c172edaa 100644 --- a/include/class.filter.php +++ b/include/class.filter.php @@ -658,7 +658,7 @@ class TicketFilter { //Clear any memoized filters $this->filters = array(); - $this->short_list = array(); + $this->short_list = null; //Query DB for "possibly" matching filters. $res = $this->vars?$this->quickList():$this->getAllActive(); @@ -681,7 +681,7 @@ class TicketFilter { */ function getMatchingFilterList() { - if (!$this->short_list) { + if (!isset($this->short_list)) { $this->short_list = array(); foreach ($this->filters as $filter) if ($filter->matches($this->vars)) -- GitLab