Skip to content

Commit

Permalink
Merge pull request #60 from microsoft/develop
Browse files Browse the repository at this point in the history
Export first cert found
  • Loading branch information
dhoehna committed May 25, 2019
2 parents d9fb026 + e2fe701 commit 4c73fc1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/scenarios/signing/ExportCertificate.ps1
Expand Up @@ -22,13 +22,13 @@ function TryGetCert
{
write-host ("Cert friendly name is: " + $CertFriendlyName)
$results = Get-ChildItem "$CertStoreLocation" | Where-Object { $_.FriendlyName -eq "$certFriendlyName" }
if ($results.Count -eq 1)
if ($results.Count -gt 1)
{
return $results[0];
}
else
{
write-Host ("There is more than one certificate with the friendly name of " + $CertFriendlyName + " in location " + $CertStoreLocation)
write-Host ("There is no certificate with the friendly name of " + $CertFriendlyName + " in location " + $CertStoreLocation)
return $null
}
}
Expand Down

0 comments on commit 4c73fc1

Please sign in to comment.