Prevent unnecessary output
This commit is contained in:
parent
7ae676141d
commit
94024951ff
1 changed files with 2 additions and 2 deletions
|
@ -174,7 +174,7 @@ function Start-EventDrivenTask() {
|
||||||
$entry = $event.SourceEventArgs.Entry;
|
$entry = $event.SourceEventArgs.Entry;
|
||||||
|
|
||||||
if ($entry.EventID -eq $EventID) {
|
if ($entry.EventID -eq $EventID) {
|
||||||
New-Event -SourceIdentifier $identifier;
|
$null = New-Event -SourceIdentifier $identifier;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -184,6 +184,6 @@ function Start-EventDrivenTask() {
|
||||||
};
|
};
|
||||||
|
|
||||||
Write-EventLog -LogName Application -Source "Application" -EventId $EventID -Message "This event was created by $env:Username";
|
Write-EventLog -LogName Application -Source "Application" -EventId $EventID -Message "This event was created by $env:Username";
|
||||||
Wait-Job $job;
|
$null = Wait-Job $job;
|
||||||
} -args $EventID
|
} -args $EventID
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue