fix(Account): 修正Credential对象的IsEmpty()方法的cred参数为null时产生异常的问题。
This commit is contained in:
parent
c6f16187a9
commit
9b5b3f6810
|
@ -131,7 +131,7 @@ public class Credential
|
|||
/// <returns></returns>
|
||||
public static bool IsEmpty(Credential cred)
|
||||
{
|
||||
return cred.Token == Guid.Empty;
|
||||
return cred is null || cred.Token == Guid.Empty;
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
|
|
Loading…
Reference in New Issue