Skip to content

Commit

Permalink
Fix CodeQL Alert AsBuiltReport#10
Browse files Browse the repository at this point in the history
  • Loading branch information
rebelinux committed May 28, 2024
1 parent 597838e commit 9a00051
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions Src/Private/Get-AbrVbrBackupServerInfo.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -469,8 +469,9 @@ function Get-AbrVbrBackupServerInfo {
Write-PScriboMessage "Infrastructure Backup Server InfoLevel set at $($InfoLevel.Infrastructure.BackupServer)."
if ($InfoLevel.Infrastructure.BackupServer -ge 2) {
Write-PScriboMessage "Collecting Backup Server Service Summary from $($BackupServer.Name)."
$Services = Invoke-Command -Session $PssSession -ScriptBlock { Get-Service Veeam* }
if ($Available = Invoke-Command -Session $PssSession -ScriptBlock { Get-Service "W32Time" | Select-Object DisplayName, Name, Status }) {
$Available = Invoke-Command -Session $PssSession -ScriptBlock { Get-Service "W32Time" | Select-Object DisplayName, Name, Status }
if ($Available) {
$Services = Invoke-Command -Session $PssSession -ScriptBlock { Get-Service Veeam* }
Section -Style Heading4 "HealthCheck - Services Status" {
$OutObj = @()
foreach ($Service in $Services) {
Expand Down

0 comments on commit 9a00051

Please sign in to comment.