Skip to content

Commit

Permalink
Merge pull request #9 from Sojaner/develop
Browse files Browse the repository at this point in the history
Print errors even if no progress bar
  • Loading branch information
Sojaner committed Mar 21, 2024
2 parents 810f361 + 4eeaa87 commit bd72880
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion TranSooner/Analyzer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,9 @@ public async Task TranslateAsync(Matcher matcher)

progressBar?.Tick();

progressBar?.WriteErrorLine($"{filePath}: {e.Message}");
Action<string> writeErrorLine = progressBar != null ? progressBar.WriteErrorLine : Console.Error.WriteLine;

writeErrorLine($"{filePath}: {e.Message}");

failed++;
}
Expand Down

0 comments on commit bd72880

Please sign in to comment.