diff options
Diffstat (limited to 'internal/importer/importer.go')
-rw-r--r-- | internal/importer/importer.go | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/internal/importer/importer.go b/internal/importer/importer.go index 0f7978d..5f251b0 100644 --- a/internal/importer/importer.go +++ b/internal/importer/importer.go @@ -4,6 +4,7 @@ import ( "context" "log/slog" "path" + "searchix/internal/config" "searchix/internal/search" "sync" ) @@ -14,7 +15,7 @@ type Importer interface { } func NewNixpkgsChannelImporter( - source *Source, + source *config.Source, dataPath string, logger *slog.Logger, ) *NixpkgsChannelImporter { @@ -27,7 +28,11 @@ func NewNixpkgsChannelImporter( } } -func NewChannelImporter(source *Source, dataPath string, logger *slog.Logger) *ChannelImporter { +func NewChannelImporter( + source *config.Source, + dataPath string, + logger *slog.Logger, +) *ChannelImporter { fullpath := path.Join(dataPath, source.Channel) return &ChannelImporter{ @@ -39,7 +44,7 @@ func NewChannelImporter(source *Source, dataPath string, logger *slog.Logger) *C type importConfig struct { Filename string - Source *Source + Source *config.Source Logger *slog.Logger } |