diff --git a/src/Microsoft.PowerShell.Commands.Utility/commands/utility/ConvertFromMarkdownCommand.cs b/src/Microsoft.PowerShell.Commands.Utility/commands/utility/ConvertFromMarkdownCommand.cs index d1052cfc42..a30d9b7a78 100644 --- a/src/Microsoft.PowerShell.Commands.Utility/commands/utility/ConvertFromMarkdownCommand.cs +++ b/src/Microsoft.PowerShell.Commands.Utility/commands/utility/ConvertFromMarkdownCommand.cs @@ -7,8 +7,8 @@ using System.Collections.ObjectModel; using System.IO; using System.Management.Automation; using System.Management.Automation.Internal; -using System.Threading.Tasks; using System.Security; +using System.Threading.Tasks; using Microsoft.PowerShell.MarkdownRender; using Dbg = System.Management.Automation; @@ -151,7 +151,7 @@ namespace Microsoft.PowerShell.Commands return mdContent; } } - catch(FileNotFoundException fnfe) + catch (FileNotFoundException fnfe) { errorRecord = new ErrorRecord( fnfe, @@ -159,7 +159,7 @@ namespace Microsoft.PowerShell.Commands ErrorCategory.ResourceUnavailable, filePath); } - catch(SecurityException se) + catch (SecurityException se) { errorRecord = new ErrorRecord( se, @@ -167,7 +167,7 @@ namespace Microsoft.PowerShell.Commands ErrorCategory.SecurityError, filePath); } - catch(UnauthorizedAccessException uae) + catch (UnauthorizedAccessException uae) { errorRecord = new ErrorRecord( uae, diff --git a/src/Microsoft.PowerShell.Commands.Utility/commands/utility/ShowMarkdownCommand.cs b/src/Microsoft.PowerShell.Commands.Utility/commands/utility/ShowMarkdownCommand.cs index c44cea4b50..53b8338cb9 100644 --- a/src/Microsoft.PowerShell.Commands.Utility/commands/utility/ShowMarkdownCommand.cs +++ b/src/Microsoft.PowerShell.Commands.Utility/commands/utility/ShowMarkdownCommand.cs @@ -44,8 +44,7 @@ namespace Microsoft.PowerShell.Commands /// protected override void BeginProcessing() { - //if (!this.MyInvocation.BoundParameters.ContainsKey("UseBrowser")) - if(!UseBrowser.IsPresent) + if (!UseBrowser.IsPresent) { // Since UseBrowser is not bound, we use proxy to Out-Default stepPipe = ScriptBlock.Create(@"Microsoft.PowerShell.Core\Out-Default @PSBoundParameters").GetSteppablePipeline(this.MyInvocation.CommandOrigin); @@ -60,7 +59,7 @@ namespace Microsoft.PowerShell.Commands { object inpObj = InputObject.BaseObject; - if(inpObj is MarkdownInfo markdownInfo) + if (inpObj is MarkdownInfo markdownInfo) { if (UseBrowser) { diff --git a/src/Microsoft.PowerShell.MarkdownRender/VT100EscapeSequences.cs b/src/Microsoft.PowerShell.MarkdownRender/VT100EscapeSequences.cs index 7b1f051ae0..dbe128a9ac 100644 --- a/src/Microsoft.PowerShell.MarkdownRender/VT100EscapeSequences.cs +++ b/src/Microsoft.PowerShell.MarkdownRender/VT100EscapeSequences.cs @@ -82,7 +82,7 @@ namespace Microsoft.PowerShell.MarkdownRender { var propName = propertyName?.ToLower(); - switch(propName) + switch (propName) { case "header1": return string.Concat(Esc, Header1, Header1, Esc, EndSequence); @@ -337,7 +337,7 @@ namespace Microsoft.PowerShell.MarkdownRender { var text = altText; - if(string.IsNullOrEmpty(altText)) + if (string.IsNullOrEmpty(altText)) { text = "Image"; }