Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8eeff2b0 authored by Bob Badour's avatar Bob Badour Committed by Gerrit Code Review
Browse files

Merge "Fix final nits from noticeindex change."

parents 92716d2d 3afc3004
Loading
Loading
Loading
Loading
+4 −6
Original line number Diff line number Diff line
@@ -231,14 +231,12 @@ func (ni *NoticeIndex) Hashes() chan hash {

// InputFiles returns the complete list of files read during indexing.
func (ni *NoticeIndex) InputFiles() []string {
	licenseMeta := []string(nil)
	for f := range ni.lg.targets {
		licenseMeta = append(licenseMeta, f)
	}
	projectMeta := ni.pmix.AllMetadataFiles()
	files := make([]string, 0, len(ni.files) + len(licenseMeta) + len(projectMeta))
	files := make([]string, 0, len(ni.files) + len(ni.lg.targets) + len(projectMeta))
	files = append(files, ni.files...)
	files = append(files, licenseMeta...)
	for f := range ni.lg.targets {
		files = append(files, f)
	}
	files = append(files, projectMeta...)
	return files
}
+1 −1
Original line number Diff line number Diff line
@@ -233,7 +233,7 @@ func (ix *Index) MetadataForProjects(projects ...string) ([]*ProjectMetadata, er

// AllMetadataFiles returns the sorted list of all METADATA files read thus far.
func (ix *Index) AllMetadataFiles() []string {
	files := []string(nil)
	var files []string
	ix.projects.Range(func(key, value any) bool {
		pi := value.(*projectIndex)
		if pi.path != "" {