Skip to content

Commit 38f819d

Browse files
authored
Fix(Forticare): Avoid warning when don't Support (#107)
Select-Object : Property 'support' cannot be found.
1 parent cad24d2 commit 38f819d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Src/Private/Get-AbrFgtFortiCare.ps1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -204,14 +204,14 @@ function Get-AbrFgtForticare {
204204

205205
Paragraph "The following section details support settings configured on FortiGate."
206206
BlankLine
207-
$ExpiresHW = (($Forticare | Select-Object -ExpandProperty support).hardware).expires
207+
$ExpiresHW = $Forticare.support.hardware.expires
208208
$SupportHW = [pscustomobject]@{
209209
"Type" = "Hardware"
210210
"Level" = $Forticare.support.hardware.support_level
211211
"Status" = $Forticare.support.hardware.status
212212
"Expiration Date" = (Get-Date 01.01.1970) + ([System.TimeSpan]::fromseconds($ExpiresHW)) | Get-Date -Format dd/MM/yyyy
213213
}
214-
$ExpiresEn = (($Forticare | Select-Object -ExpandProperty support).enhanced).expires
214+
$ExpiresEn = $Forticare.support.enhanced.expires
215215
$SupportEn = [pscustomobject]@{
216216
"Type" = "Enhanced"
217217
"Level" = $Forticare.support.enhanced.support_level

0 commit comments

Comments
 (0)