Skip to content

Commit 3a56bf4

Browse files
Merge pull request #1514 from VictoriousRaptor/Fix1476
[Dev] Fix unwanted URL protocols and invalid programs in custom sources
2 parents 805680e + b8a68fe commit 3a56bf4

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
@@ -390,7 +390,6 @@ private static IEnumerable<Win32> UnregisteredPrograms(List<Settings.ProgramSour
390390
_ => Win32Program(x)
391391
});
392392

393-
394393
return programs;
395394
}
396395

@@ -411,7 +410,7 @@ private static IEnumerable<Win32> StartMenuPrograms(string[] suffixes)
411410
ShortcutExtension => LnkProgram(x),
412411
UrlExtension => UrlProgram(x),
413412
_ => Win32Program(x)
414-
}).Where(x => x.Valid);
413+
});
415414
return programs;
416415
}
417416

@@ -569,7 +568,7 @@ public static Win32[] All(Settings settings)
569568

570569
autoIndexPrograms = ProgramsHasher(autoIndexPrograms);
571570

572-
return programs.Concat(autoIndexPrograms).Distinct().ToArray();
571+
return programs.Concat(autoIndexPrograms).Where(x => x.Valid).Distinct().ToArray();
573572
}
574573
#if DEBUG //This is to make developer aware of any unhandled exception and add in handling.
575574
catch (Exception)

0 commit comments

Comments
 (0)