Skip to content

Commit ed396ce

Browse files
authored
Merge pull request #36406 from joncloud/cmdlet-optimize-filter
Optimizes Get-AzResource Filtering
2 parents 85c0622 + 1c7ecd3 commit ed396ce

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

articles/network-watcher/network-watcher-packet-capture-manage-powershell.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ Once the preceding steps are complete, the packet capture agent is installed on
123123
The next step is to retrieve the Network Watcher instance. This variable is passed to the `New-AzNetworkWatcherPacketCapture` cmdlet in step 4.
124124

125125
```powershell
126-
$networkWatcher = Get-AzResource | Where {$_.ResourceType -eq "Microsoft.Network/networkWatchers" -and $_.Location -eq "WestCentralUS" }
126+
$networkWatcher = Get-AzResource -ResourceType "Microsoft.Network/networkWatchers" | Where {$_.Location -eq "WestCentralUS" }
127127
```
128128

129129
### Step 2

0 commit comments

Comments
 (0)