We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent fbd123c commit c98d10eCopy full SHA for c98d10e
1 file changed
Rubjerg.Graphviz/GraphvizCommand.cs
@@ -43,8 +43,8 @@ internal static string Rid
43
Path.GetDirectoryName(AppContext.BaseDirectory),
44
""
45
];
46
- return possibleLocations.FirstOrDefault(dir => File.Exists(Path.Combine(dir, "dot")))
47
- ?? possibleLocations.FirstOrDefault(dir => File.Exists(Path.Combine(dir, "dot.exe")))
+ return possibleLocations.Select(dir => Path.Combine(dir, "dot")).FirstOrDefault(File.Exists)
+ ?? possibleLocations.Select(dir => Path.Combine(dir, "dot.exe")).FirstOrDefault(File.Exists)
48
?? throw new InvalidOperationException("Could not find path to dot binary");
49
});
50
internal static string DotExePath => _DotExePath.Value;
0 commit comments