Find implements the [Finder] interface.
(fsys afero.Fs)
| 34 | |
| 35 | // Find implements the [Finder] interface. |
| 36 | func (c *combinedFinder) Find(fsys afero.Fs) ([]string, error) { |
| 37 | var results []string |
| 38 | var errs []error |
| 39 | |
| 40 | for _, finder := range c.finders { |
| 41 | if finder == nil { |
| 42 | continue |
| 43 | } |
| 44 | |
| 45 | r, err := finder.Find(fsys) |
| 46 | if err != nil { |
| 47 | errs = append(errs, err) |
| 48 | continue |
| 49 | } |
| 50 | |
| 51 | results = append(results, r...) |
| 52 | } |
| 53 | |
| 54 | return results, errors.Join(errs...) |
| 55 | } |