File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed
Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -32,10 +32,15 @@ function Get-AbrFgtRoute {
3232 $MonitorRouterIPv4 = Get-FGTMonitorRouterIPv4
3333 $Statics = Get-FGTRouterStatic
3434 $PolicyBasedRouting = Get-FGTRouterPolicy
35- $BGPNeighbors = Get-FGTMonitorRouterBGPNeighbors
35+ #
36+ try {
37+ $BGPNeighbors = Get-FGTMonitorRouterBGPNeighbors
38+ $OSPFNeighbors = Get-FGTMonitorRouterOSPFNeighbors
39+ } catch {
40+ Write-Warning " BGP/OSPF Neighbor are not available"
41+ }
3642 $BGP = Get-FGTRouterBGP
3743 $BGPSchema = (Invoke-FGTRestMethod ' api/v2/cmdb/router/bgp?&action=schema' ).results.children
38- $OSPFNeighbors = Get-FGTMonitorRouterOSPFNeighbors
3944 $OSPF = Get-FGTRouterOSPF
4045 $OSPFSchema = (Invoke-FGTRestMethod ' api/v2/cmdb/router/ospf?&action=schema' ).results.children
4146
You can’t perform that action at this time.
0 commit comments