[Modify] Polish it

This commit is contained in:
sta 2019-01-23 21:21:41 +09:00
parent ac5559b15d
commit bfbc42097e

View File

@ -801,15 +801,15 @@ namespace WebSocketSharp.Net
if (cred == null) if (cred == null)
return null; return null;
if (scheme == AuthenticationSchemes.Basic if (scheme == AuthenticationSchemes.Basic) {
&& ((HttpBasicIdentity) id).Password != cred.Password var basicId = (HttpBasicIdentity) id;
) { if (basicId.Password != cred.Password)
return null; return null;
} }
if (scheme == AuthenticationSchemes.Digest if (scheme == AuthenticationSchemes.Digest) {
&& !((HttpDigestIdentity) id).IsValid (cred.Password, realm, method, null) var digestId = (HttpDigestIdentity) id;
) { if (!digestId.IsValid (cred.Password, realm, method, null))
return null; return null;
} }