Skip to content

Commit

Permalink
Provide a more informative message when the CAPI refresh token is not…
Browse files Browse the repository at this point in the history
… valid.
  • Loading branch information
Tkael committed Jan 18, 2025
1 parent 8df29e9 commit 3d90841
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion CompanionAppService/CompanionAppService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -376,7 +376,12 @@ private void RefreshToken()
}
catch ( WebException webException )
{
Logging.Warn(webException.Message, webException);
if ( webException.Status == WebExceptionStatus.TrustFailure )
{
throw new EliteDangerousCompanionAppAuthenticationException( "Refresh token not valid, need full login" );
}

Logging.Warn( webException.Message, webException );
}

using ( var response = GetResponse(request) )
Expand Down

0 comments on commit 3d90841

Please sign in to comment.