Skip to content

Commit 619cc33

Browse files
Apply suggestion from @Copilot
Suggestion accepted Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
1 parent 666e9f2 commit 619cc33

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

Diagnostics/FreeBusyChecker/Functions/OnPremOAuthFunctions.ps1

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,10 @@ function AuthServerCheck {
5151
#PrintDynamicWidthLine
5252
Write-Host -ForegroundColor Green " Get-AuthServer | Select Name, Realm, IssuerIdentifier, TokenIssuingEndpoint, AuthMetadataUrl, Enabled"
5353
PrintDynamicWidthLine
54-
$AuthServer = Get-AuthServer | Where-Object { $_.Name -like "EvoSts*" } | Select-Object Name, Realm, IssuerIdentifier, TokenIssuingEndpoint, AuthMetadataUrl, Enabled
54+
$AuthServer = Get-AuthServer |
55+
Where-Object { $_.Name -like "EvoSts*" } |
56+
Sort-Object Name |
57+
Select-Object -First 1 Name, Realm, IssuerIdentifier, TokenIssuingEndpoint, AuthMetadataUrl, Enabled
5558
$AuthServer
5659
$Script:tDAuthServerIssuerIdentifier = $AuthServer.IssuerIdentifier
5760
$Script:tDAuthServerTokenIssuingEndpoint = $AuthServer.TokenIssuingEndpoint

0 commit comments

Comments
 (0)