Skip to content

Commit

Permalink
fix annotated data issue where it returns nil initialised errors.
Browse files Browse the repository at this point in the history
  • Loading branch information
jonhadfield committed Apr 29, 2024
1 parent 9183bc8 commit e05f0d8
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion providers/annotated/annotated.go
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,11 @@ func ReadAnnotatedPrefixesFromFile(l *slog.Logger, path string, prefixesWithAnno
}
}

return fmt.Errorf("error parsing prefixes: %w", err)
if err != nil {
return fmt.Errorf("error parsing prefixes: %w", err)
}

return nil
}

func parseAndRepackYAMLAnnotations(l *slog.Logger, source string, yas []yamlAnnotation) (pyas []annotation) {
Expand Down

0 comments on commit e05f0d8

Please sign in to comment.