Login()添加异常捕获

croire 3 years ago
parent dc199a4559
commit 59c75e3fdd

@ -97,6 +97,8 @@ namespace DownKyi.ViewModels
/// 登录 /// 登录
/// </summary> /// </summary>
private void Login() private void Login()
{
try
{ {
var loginUrl = LoginQR.GetLoginUrl(); var loginUrl = LoginQR.GetLoginUrl();
if (loginUrl == null) { return; } if (loginUrl == null) { return; }
@ -119,6 +121,12 @@ namespace DownKyi.ViewModels
GetLoginStatus(loginUrl.Data.OauthKey); GetLoginStatus(loginUrl.Data.OauthKey);
} }
catch (Exception e)
{
Core.Utils.Debugging.Console.PrintLine("Login()发生异常: {0}", e);
LogManager.Error(Tag, e);
}
}
/// <summary> /// <summary>
/// 循环查询登录状态 /// 循环查询登录状态

Loading…
Cancel
Save