Remove toarray() in ProgramsHasher

This commit is contained in:
Vic 2022-11-17 01:27:58 +08:00
parent 37cc01e5ed
commit d1e8bbf9ff

View file

@ -553,7 +553,7 @@ namespace Flow.Launcher.Plugin.Program.Programs
if (temp.Any()) if (temp.Any())
return DistinctBy(temp, x => x.Description); return DistinctBy(temp, x => x.Description);
return g.Take(1); return g.Take(1);
}).ToArray(); });
} }
@ -589,7 +589,7 @@ namespace Flow.Launcher.Plugin.Program.Programs
autoIndexPrograms = autoIndexPrograms.Concat(path); autoIndexPrograms = autoIndexPrograms.Concat(path);
} }
autoIndexPrograms = ProgramsHasher(autoIndexPrograms); autoIndexPrograms = ProgramsHasher(autoIndexPrograms).ToArray();
return programs.Concat(autoIndexPrograms).Where(x => x.Valid).Distinct().ToArray(); return programs.Concat(autoIndexPrograms).Where(x => x.Valid).Distinct().ToArray();
} }