Skip to content

Commit

Permalink
fix wrong var
Browse files Browse the repository at this point in the history
  • Loading branch information
Lea9250 committed Sep 10, 2021
1 parent 51715ab commit 87514f9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion agent/pendingreboot.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ if ($WMI_Reg) {
#Checking for SCCM namespace
$SCCM_Namespace = Get-WmiObject -Namespace ROOT\CCM\ClientSDK -List -ComputerName $ComputerName -ErrorAction Ignore
if ($SCCM_Namespace) {
if (([WmiClass]"\\$Computer\ROOT\CCM\ClientSDK:CCM_ClientUtilities").DetermineIfRebootPending().RebootPending -eq $true) {$PendingReboot = $true}
if (([WmiClass]"\\$ComputerName\ROOT\CCM\ClientSDK:CCM_ClientUtilities").DetermineIfRebootPending().RebootPending -eq $true) {$PendingReboot = $true}
}

$lastChecked = Get-Date -Format("yyyy-MM-dd HH:mm:ss")
Expand Down

0 comments on commit 87514f9

Please sign in to comment.