Skip to content

Commit

Permalink
epss: add NewFactory()
Browse files Browse the repository at this point in the history
Signed-off-by: daynewlee <[email protected]>
  • Loading branch information
daynewlee committed Jan 6, 2025
1 parent 6bbe356 commit 61550ea
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions enricher/epss/epss.go
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,13 @@ type Config struct {
URL *string `json:"url" yaml:"url"`
}

// NewFactory creates a Factory for the EPSS enricher.
func NewFactory() driver.UpdaterSetFactory {
set := driver.NewUpdaterSet()
_ = set.Add(&Enricher{})
return driver.StaticSet(set)
}

func (e *Enricher) Configure(ctx context.Context, f driver.ConfigUnmarshaler, c *http.Client) error {
ctx = zlog.ContextWithValues(ctx, "component", "enricher/epss/Enricher/Configure")
var cfg Config
Expand Down

0 comments on commit 61550ea

Please sign in to comment.