mirror of
https://github.com/M66B/FairEmail.git
synced 2024-12-28 18:59:01 +00:00
Small improvement
This commit is contained in:
parent
195b40a330
commit
f98e3ee1fe
1 changed files with 4 additions and 1 deletions
|
@ -50,6 +50,7 @@ import androidx.preference.PreferenceManager;
|
|||
|
||||
import com.sun.mail.imap.IMAPFolder;
|
||||
|
||||
import java.net.SocketException;
|
||||
import java.text.DateFormat;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
|
@ -740,7 +741,9 @@ public class ServiceSynchronize extends ServiceBase implements SharedPreferences
|
|||
try {
|
||||
iservice.connect(account);
|
||||
} catch (Throwable ex) {
|
||||
if (ex instanceof AuthenticationFailedException) {
|
||||
// Immediately report auth errors
|
||||
if (ex instanceof AuthenticationFailedException &&
|
||||
!(ex.getCause() instanceof SocketException)) {
|
||||
NotificationManager nm = (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);
|
||||
nm.notify("receive:" + account.id, 1,
|
||||
Core.getNotificationError(this, "error", account.name, ex)
|
||||
|
|
Loading…
Reference in a new issue