From e00362e7c902a9a0d19de4df77c387dfafe7ea24 Mon Sep 17 00:00:00 2001 From: Alex Gleason Date: Sat, 12 Aug 2023 12:25:55 -0500 Subject: [PATCH] Filter: let tag queries be undefined --- filter.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/filter.ts b/filter.ts index bd59c08..9ca2730 100644 --- a/filter.ts +++ b/filter.ts @@ -8,7 +8,7 @@ export type Filter = { until?: number limit?: number search?: string - [key: `#${string}`]: string[] + [key: `#${string}`]: string[] | undefined } export function matchFilter( @@ -34,7 +34,7 @@ export function matchFilter( if ( values && !event.tags.find( - ([t, v]) => t === f.slice(1) && values.indexOf(v) !== -1 + ([t, v]) => t === f.slice(1) && values!.indexOf(v) !== -1 ) ) return false