refactor: Improve logging

This commit is contained in:
Sculas 2025-01-07 15:15:31 +01:00
parent 38a3bc1537
commit 56934e3183
No known key found for this signature in database
GPG key ID: 1530BFF96D1EEB89

View file

@ -69,9 +69,13 @@ public class SymlinkDownloader(String uri, String destinationPath, String path,
// If this somehow fails, fallback to the search below.
if (File.Exists(potentialFilePath))
{
_logger.Debug($"Found file {path} at {potentialFilePath} using direct search");
file = potentialFilePath;
goto skipFileSearch;
}
// Log if the file wasn't found and continue searching.
_logger.Warning($"Expected file {path} to be at {potentialFilePath} but it wasn't found. Continuing search (this will probably fail).");
}
var potentialFilePaths = new List<String> { searchPath };