From 94d6ffe6f9dd15d2d4badbeaa521883f3c59820c Mon Sep 17 00:00:00 2001 From: Manuel Thalmann Date: Sat, 10 Aug 2024 01:50:52 +0200 Subject: [PATCH] Fix broken scripts --- scripts/Windows/OS/Install.ps1 | 2 +- scripts/Windows/Scripts/PowerManagement.ps1 | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/Windows/OS/Install.ps1 b/scripts/Windows/OS/Install.ps1 index dc624ff4..80ff76c6 100644 --- a/scripts/Windows/OS/Install.ps1 +++ b/scripts/Windows/OS/Install.ps1 @@ -101,7 +101,7 @@ $null = New-Module { if (-not (& { $null = wsl -l; $?; })) { $wslRoot = Split-Path -Parent $wslLocation; - if (-not (Test-Path -PathType $wslRoot)) { + if (-not (Test-Path $wslRoot)) { $null = New-Item -ItemType Directory $wslRoot; } diff --git a/scripts/Windows/Scripts/PowerManagement.ps1 b/scripts/Windows/Scripts/PowerManagement.ps1 index a4d028be..69f834cc 100644 --- a/scripts/Windows/Scripts/PowerManagement.ps1 +++ b/scripts/Windows/Scripts/PowerManagement.ps1 @@ -77,7 +77,7 @@ $null = New-Module { [switch] $System, [Parameter(ParameterSetName="User",Mandatory)] [switch] $User, - [Parameter(Mandatory)] + [Parameter(ParameterSetName="User")] [RegistryKey] $UserKey )