Skip to content

Commit

Permalink
Fix issue
Browse files Browse the repository at this point in the history
  • Loading branch information
andreasjordan committed Sep 29, 2023
1 parent ff1df4c commit 69f1123
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions public/Get-DbaAvailabilityGroup.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,9 @@ function Get-DbaAvailabilityGroup {
}

foreach ($ag in $ags) {
# Refresh list of databases to fix #9094
$ag.AvailabilityDatabases.Refresh()

Add-Member -Force -InputObject $ag -MemberType NoteProperty -Name ComputerName -value $server.ComputerName
Add-Member -Force -InputObject $ag -MemberType NoteProperty -Name InstanceName -value $server.ServiceName
Add-Member -Force -InputObject $ag -MemberType NoteProperty -Name SqlInstance -value $server.DomainInstanceName
Expand Down

0 comments on commit 69f1123

Please sign in to comment.