Skip to content

Commit 01ecf4b

Browse files
committed
[Feature] Address Steve's new comments
1 parent 6ee608f commit 01ecf4b

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

src/System.Management.Automation/engine/PSConfiguration.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -498,7 +498,7 @@ private void RemoveValueFromFile<T>(string fileName, string key)
498498

499499
/// <summary>
500500
/// The GroupPolicy related settings used in PowerShell are as follows in Registry:
501-
/// - Software\Policies\Microsoft\Windows\PowerShell -- { EnableScripts (0 or 1); ExecutionPolicy (string) }
501+
/// - Software\Policies\Microsoft\PowerShellCore -- { EnableScripts (0 or 1); ExecutionPolicy (string) }
502502
/// SubKeys Name-Value-Pairs
503503
/// - ScriptBlockLogging { EnableScriptBlockLogging (0 or 1); EnableScriptBlockInvocationLogging (0 or 1) }
504504
/// - ModuleLogging { EnableModuleLogging (0 or 1); ModuleNames (string[]) }
@@ -528,10 +528,10 @@ private void RemoveValueFromFile<T>(string fileName, string key)
528528
/// "Transcription": {
529529
/// "EnableTranscripting": true,
530530
/// "EnableInvocationHeader": true,
531-
/// "OutputDirectory": "c:\tmp"
531+
/// "OutputDirectory": "c:\\tmp"
532532
/// },
533533
/// "UpdatableHelp": {
534-
/// "DefaultSourcePath": "f:\temp"
534+
/// "DefaultSourcePath": "f:\\temp"
535535
/// },
536536
/// "ConsoleSessionConfiguration": {
537537
/// "EnableConsoleSessionConfiguration": true,

src/System.Management.Automation/engine/Utils.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -551,7 +551,7 @@ internal static bool IsValidPSEditionValue(string editionValue)
551551
case nameof(Transcription): result = policies.Transcription; break;
552552
case nameof(UpdatableHelp): result = policies.UpdatableHelp; break;
553553
case nameof(ConsoleSessionConfiguration): result = policies.ConsoleSessionConfiguration; break;
554-
default: Diagnostics.Assert(false, "Unreachable code"); break;
554+
default: Diagnostics.Assert(false, "Should be unreachable code. Update this switch block when new PowerShell policy types are added."); break;
555555
}
556556
if (result != null) { return (T) result; }
557557
}

0 commit comments

Comments
 (0)