From 9015baf955c94a806c01b3dcd5648c8e68ad2685 Mon Sep 17 00:00:00 2001 From: Alan Pearce Date: Wed, 12 Mar 2025 22:39:51 +0100 Subject: refactor: ensure errors have stack traces --- internal/importer/main.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'internal/importer/main.go') diff --git a/internal/importer/main.go b/internal/importer/main.go index 7181926..e2c222c 100644 --- a/internal/importer/main.go +++ b/internal/importer/main.go @@ -14,7 +14,7 @@ import ( "go.alanpearce.eu/searchix/internal/programs" "go.alanpearce.eu/x/log" - "github.com/pkg/errors" + "gitlab.com/tozd/go/errors" ) func createSourceImporter( @@ -23,8 +23,8 @@ func createSourceImporter( meta *index.Meta, indexer *index.WriteIndex, forceUpdate bool, -) func(*config.Source) error { - return func(source *config.Source) error { +) func(*config.Source) errors.E { + return func(source *config.Source) errors.E { logger := log.With( "name", source.Key, @@ -165,7 +165,7 @@ func (imp *Importer) Start( ctx context.Context, forceUpdate bool, onlyUpdateSources *[]string, -) error { +) errors.E { if len(imp.config.Importer.Sources) == 0 { imp.log.Info("No sources enabled") -- cgit 1.4.1