From a2f0ae607889d8fe9b5f6fef684dfd5590eb160b Mon Sep 17 00:00:00 2001 From: Bhadra Date: Mon, 12 Jan 2026 12:14:15 +0530 Subject: [PATCH] fix: repair command icon and null input handling - Replace non-existent Icons.Mole with Icons.Admin - Add null check for empty menu input --- bin/repair.ps1 | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/bin/repair.ps1 b/bin/repair.ps1 index 61adc0c..1942a75 100644 --- a/bin/repair.ps1 +++ b/bin/repair.ps1 @@ -370,7 +370,7 @@ function Show-RepairMenu { ) Write-Host "" - Write-Host "$esc[1;35m$($script:Icons.Mole) Mole Repair$esc[0m" + Write-Host "$esc[1;35m$($script:Icons.Admin) Mole Repair$esc[0m" Write-Host "" if ($script:IsDryRun) { @@ -388,6 +388,10 @@ function Show-RepairMenu { Write-Host "" $choice = Read-Host "Choice" + if ([string]::IsNullOrWhiteSpace($choice)) { + return + } + $selected = $menuItems | Where-Object { $_.Key -eq $choice.ToUpper() } if ($selected -and $selected.Action) { @@ -440,7 +444,7 @@ function Main { # Run specific repairs Write-Host "" - Write-Host "$esc[1;35m$($script:Icons.Mole) Mole Repair$esc[0m" + Write-Host "$esc[1;35m$($script:Icons.Admin) Mole Repair$esc[0m" if ($script:IsDryRun) { Write-Host ""