about summary refs log tree commit diff stats
path: root/internal/search/search.go
diff options
context:
space:
mode:
authorAlan Pearce2024-05-08 08:26:11 +0200
committerAlan Pearce2024-05-08 08:26:11 +0200
commit5e008c251cf0e91ca6cdf9d91faaaa4975636541 (patch)
treee94c989a1781111dc1d492cc57a25ff8f0b757dc /internal/search/search.go
parent973345ad50f9b237714fcb364cf7f665b3909f9d (diff)
downloadsearchix-5e008c251cf0e91ca6cdf9d91faaaa4975636541.tar.lz
searchix-5e008c251cf0e91ca6cdf9d91faaaa4975636541.tar.zst
searchix-5e008c251cf0e91ca6cdf9d91faaaa4975636541.zip
fix: incorrect data shown for default and example option keys
Diffstat (limited to 'internal/search/search.go')
-rw-r--r--internal/search/search.go1
1 files changed, 1 insertions, 0 deletions
diff --git a/internal/search/search.go b/internal/search/search.go
index 83a8365..b7640fc 100644
--- a/internal/search/search.go
+++ b/internal/search/search.go
@@ -69,6 +69,7 @@ func New[T options.NixOption](kind string) (*Index[T], error) {
 		return nil, errors.WithMessage(err, "could not create struct decoder")
 	}
 	for mv := range dec.Stream() {
+		opt = options.NixOption{}
 		err := ms.Decode(mv.Value) // stores in opt
 
 		if err != nil {