Skip to content

Commit

Permalink
C#: Address review comments.
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelnebel committed Dec 10, 2024
1 parent 86c6df5 commit 684c80c
Showing 1 changed file with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -606,7 +606,12 @@ private bool IsFeedReachable(string feed, int timeoutMilliSeconds, int tryCount,
{
if (chain is null || cert is null)
{
logger.LogWarning("Certificate validation trivially failed due to missing chain or certificate.");
var msg = cert is null && chain is null
? "certificate and chain"
: chain is null
? "chain"
: "certificate";
logger.LogWarning($"Dependabot proxy certificate validation failed due to missing {msg}");
return false;
}
chain.ChainPolicy.TrustMode = X509ChainTrustMode.CustomRootTrust;
Expand Down

0 comments on commit 684c80c

Please sign in to comment.