diff --git a/dotnet/samples/03-workflows/Orchestration/Magentic/Program.cs b/dotnet/samples/03-workflows/Orchestration/Magentic/Program.cs index 7685ae7adc..6b4a5d675e 100644 --- a/dotnet/samples/03-workflows/Orchestration/Magentic/Program.cs +++ b/dotnet/samples/03-workflows/Orchestration/Magentic/Program.cs @@ -183,7 +183,7 @@ public static class Program private static void PauseIfInteractive() { - if (Console.IsInputRedirected) + if (Console.IsInputRedirected || Console.IsOutputRedirected) { return; }