Skip to content

Commit 165aa90

Browse files
Fix indexing unwanted protocols in custom sources
1 parent 805680e commit 165aa90

File tree

1 file changed

+2
-3
lines changed
  • Plugins/Flow.Launcher.Plugin.Program/Programs

1 file changed

+2
-3
lines changed

Plugins/Flow.Launcher.Plugin.Program/Programs/Win32.cs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -388,8 +388,7 @@ private static IEnumerable<Win32> UnregisteredPrograms(List<Settings.ProgramSour
388388
ShortcutExtension => LnkProgram(x),
389389
UrlExtension => UrlProgram(x),
390390
_ => Win32Program(x)
391-
});
392-
391+
}).Where(x => x.Valid);
393392

394393
return programs;
395394
}
@@ -440,7 +439,7 @@ private static IEnumerable<Win32> AppPathsPrograms(string[] suffixes)
440439

441440
var filtered = ExceptDisabledSource(toFilter);
442441

443-
return filtered.Select(GetProgramFromPath).ToList(); // ToList due to disposing issue
442+
return filtered.Select(GetProgramFromPath).Where(x => x.Valid).ToList(); // ToList due to disposing issue
444443
}
445444

446445
private static IEnumerable<string> GetPathFromRegistry(RegistryKey root)

0 commit comments

Comments
 (0)