mirror of https://github.com/M66B/FairEmail.git
Prefer auth exception
This commit is contained in:
parent
68d1c8b03e
commit
81f9e16a4b
|
@ -317,6 +317,7 @@ public class FragmentQuickSetup extends FragmentBase {
|
||||||
} else
|
} else
|
||||||
throw ex;
|
throw ex;
|
||||||
} catch (Throwable ex) {
|
} catch (Throwable ex) {
|
||||||
|
Log.w(ex);
|
||||||
// Why not AuthenticationFailedException?
|
// Why not AuthenticationFailedException?
|
||||||
// Some providers terminate the connection with an invalid username
|
// Some providers terminate the connection with an invalid username
|
||||||
if (user.equals(username))
|
if (user.equals(username))
|
||||||
|
@ -332,7 +333,11 @@ public class FragmentQuickSetup extends FragmentBase {
|
||||||
null, null);
|
null, null);
|
||||||
} catch (Throwable ex1) {
|
} catch (Throwable ex1) {
|
||||||
Log.w(ex1);
|
Log.w(ex1);
|
||||||
throw ex;
|
if (!(ex instanceof AuthenticationFailedException) &&
|
||||||
|
ex1 instanceof AuthenticationFailedException)
|
||||||
|
throw ex1;
|
||||||
|
else
|
||||||
|
throw ex;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue