diff options
author | Christian Schneppe <christian@pix-art.de> | 2018-11-23 12:32:34 +0100 |
---|---|---|
committer | Christian Schneppe <christian@pix-art.de> | 2018-11-23 12:32:34 +0100 |
commit | f7fea5a35adae306326de57da22420c52bfc4517 (patch) | |
tree | c0ec45e360dac387271023cea956a0c800aad4ed /src/main/java/de/pixart/messenger/services | |
parent | 7d584fbee00a5a74fbd14df6a9a98a47e112304e (diff) |
refresh contacts when opening StartConversationsActivity
Diffstat (limited to 'src/main/java/de/pixart/messenger/services')
-rw-r--r-- | src/main/java/de/pixart/messenger/services/NotificationService.java | 3 | ||||
-rw-r--r-- | src/main/java/de/pixart/messenger/services/XmppConnectionService.java | 4 |
2 files changed, 6 insertions, 1 deletions
diff --git a/src/main/java/de/pixart/messenger/services/NotificationService.java b/src/main/java/de/pixart/messenger/services/NotificationService.java index 053685fc6..91501f623 100644 --- a/src/main/java/de/pixart/messenger/services/NotificationService.java +++ b/src/main/java/de/pixart/messenger/services/NotificationService.java @@ -929,9 +929,10 @@ public class NotificationService { cancel(ERROR_NOTIFICATION_ID); return; } + final boolean showAllErrors = QuickConversationsService.isConversations(); final List<Account> errors = new ArrayList<>(); for (final Account account : mXmppConnectionService.getAccounts()) { - if (account.hasErrorStatus() && account.showErrorNotification()) { + if (account.hasErrorStatus() && account.showErrorNotification() && (showAllErrors || account.getLastErrorStatus() == Account.State.UNAUTHORIZED)) { errors.add(account); } } diff --git a/src/main/java/de/pixart/messenger/services/XmppConnectionService.java b/src/main/java/de/pixart/messenger/services/XmppConnectionService.java index e9f77b33b..174785fb8 100644 --- a/src/main/java/de/pixart/messenger/services/XmppConnectionService.java +++ b/src/main/java/de/pixart/messenger/services/XmppConnectionService.java @@ -4041,6 +4041,10 @@ public class XmppConnectionService extends Service { return this.mMessageArchiveService; } + public QuickConversationsService getQuickConversationsService() { + return this.mQuickConversationsService; + } + public List<Contact> findContacts(Jid jid, String accountJid) { ArrayList<Contact> contacts = new ArrayList<>(); for (Account account : getAccounts()) { |