Skip to content

Commit

Permalink
address Ilya's feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
SteveL-MSFT committed Aug 12, 2020
1 parent f651490 commit 957f516
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 18 deletions.
Expand Up @@ -885,7 +885,7 @@ private void ParseHelper(string[] args)
++i;
if (i >= args.Length)
{
WriteCommandLineError(
SetCommandLineError(
CommandLineParameterParserStrings.MissingOutputLogParameter);
break;
}
Expand Down Expand Up @@ -995,21 +995,6 @@ private void ParseHelper(string[] args)
}
}

if (_showHelp)
{
ShowHelp();
}

if (_showBanner && !_showHelp)
{
DisplayBanner();

if (UpdatesNotification.CanNotifyUpdates)
{
UpdatesNotification.ShowUpdateNotification(_hostUI);
}
}

if (string.Equals(AppDomain.CurrentDomain.FriendlyName, ConsoleHost.PwshwHost, StringComparison.OrdinalIgnoreCase))
{
_noInteractive = true;
Expand Down Expand Up @@ -1371,7 +1356,7 @@ private bool CollectArgs(string[] args, ref int i)
private bool _wasCommandEncoded;
private uint _exitCode = ConsoleHost.ExitCodeSuccess;
private bool _dirty;
private string _outputLog;
private string _outputLog = String.Empty;
private Serialization.DataFormat _outFormat = Serialization.DataFormat.Text;
private bool _outputFormatSpecified = false;
private Serialization.DataFormat _inFormat = Serialization.DataFormat.Text;
Expand Down
Expand Up @@ -576,7 +576,7 @@ private void WriteToConsole(ReadOnlySpan<char> value, bool transcribeResult, boo
ConsoleControl.ConsoleModes.ProcessedOutput
| ConsoleControl.ConsoleModes.WrapEndOfLine;

if ((m & DesiredMode) != DesiredMode)
if (!m.HasFlag(DesiredMode))
{
m |= DesiredMode;
ConsoleControl.SetMode(handle, m);
Expand Down

0 comments on commit 957f516

Please sign in to comment.