Merge pull request #698 from erri120/mega-tfa

Mega TFA fix
This commit is contained in:
Timothy Baldridge 2020-04-10 05:16:17 -06:00 committed by GitHub
commit ea1b4a1661
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 5 deletions

View File

@ -44,12 +44,10 @@ namespace Wabbajack.Lib.Downloaders
}
catch (ApiException e)
{
if ((int)e.ApiResultCode == -26)
{
return new LoginReturnMessage("Two-Factor Authentication needs to be disabled before login!", true);
}
return e.ApiResultCode switch
{
ApiResultCode.TwoFactorAuthenticationError => new LoginReturnMessage(
$"Two-Factor Authentication needs to be disabled before login! {e.Message}", true),
ApiResultCode.InternalError => new LoginReturnMessage(
$"Internal error occured! Please report this to the Wabbajack Team! {e.Message}", true),
_ => new LoginReturnMessage($"Error during login: {e.Message}", true)

View File

@ -25,7 +25,7 @@
<Version>1.11.23</Version>
</PackageReference>
<PackageReference Include="MegaApiClient">
<Version>1.7.1</Version>
<Version>1.8.0</Version>
</PackageReference>
<PackageReference Include="Microsoft.CSharp">
<Version>4.7.0</Version>