Skip to content

Commit

Permalink
handle 5003 error
Browse files Browse the repository at this point in the history
  • Loading branch information
Scighost committed Nov 9, 2023
1 parent 09237c1 commit 06fcd02
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ private async Task RefreshDataAsync()
catch (miHoYoApiException ex)
{
_logger.LogError(ex, "Refresh forgotten hall data ({gameBiz}, {uid}).", gameRole?.GameBiz, gameRole?.Uid);
if (ex.ReturnCode == 1034)
if (ex.ReturnCode is 1034 or 5003)
{
NotificationBehavior.Instance.ShowWithButton(InfoBarSeverity.Warning, Lang.Common_AccountError, ex.Message, Lang.HoyolabToolboxPage_VerifyAccount, () =>
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ private async Task GetSimulatedUniverseInfoBasicAsync(bool detail = false)
catch (miHoYoApiException ex)
{
_logger.LogError(ex, "Get simulated universe data ({gameBiz}, {uid}).", gameRole?.GameBiz, gameRole?.Uid);
if (ex.ReturnCode == 1034)
if (ex.ReturnCode is 1034 or 5003)
{
NotificationBehavior.Instance.ShowWithButton(InfoBarSeverity.Warning, Lang.Common_AccountError, ex.Message, Lang.HoyolabToolboxPage_VerifyAccount, () =>
{
Expand Down
2 changes: 1 addition & 1 deletion src/Starward/Pages/HoyolabToolbox/SpiralAbyssPage.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ private async Task RefreshDataAsync()
catch (miHoYoApiException ex)
{
_logger.LogError(ex, "Refresh abyss data ({gameBiz}, {uid}).", gameRole?.GameBiz, gameRole?.Uid);
if (ex.ReturnCode == 1034)
if (ex.ReturnCode is 1034 or 5003)
{
NotificationBehavior.Instance.ShowWithButton(InfoBarSeverity.Warning, Lang.Common_AccountError, ex.Message, Lang.HoyolabToolboxPage_VerifyAccount, () =>
{
Expand Down

0 comments on commit 06fcd02

Please sign in to comment.