From e1c7b9c5750411e22101ab4d9a5eaec02f05a7d9 Mon Sep 17 00:00:00 2001 From: bobloy Date: Mon, 14 Sep 2020 10:28:59 -0400 Subject: [PATCH] Search id and tags --- index.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/index.php b/index.php index 42611a4..73756c6 100644 --- a/index.php +++ b/index.php @@ -44,8 +44,8 @@ foreach($json as $source => $sourceData){ foreach($cog['tags'] as $index => $this_tag){$cog['tags'][$index] = strtolower($this_tag);} if($filter && !in_array(strtolower($filter), $cog['tags'])){ continue; } if($search && strpos(strtolower($cog['id']), strtolower($search)) === false){ - if(strpos(strtolower($cog['description'] ?: $cog['short']), strtolower($search)) === false){ - continue; + if(strpos(strtolower($cog['description'] ?: $cog['short']), strtolower($search)) === false && strpos($cog['id'], strtolower($search)) === false && !in_array(strtolower($search), $cog['tags'])){ + continue; } } array_push($cogs, $cog);