Fix crash when notification state is empty.
This commit is contained in:
parent
fea2b6253f
commit
5d54ebfaa0
1 changed files with 6 additions and 1 deletions
|
@ -340,7 +340,7 @@ public class MessageNotifier {
|
|||
|
||||
if (notificationState.getNotifications().isEmpty()) {
|
||||
if (!bundled) cancelActiveNotifications(context);
|
||||
Log.i(TAG, "Empty notification state. Skipping.");
|
||||
Log.i(TAG, "[sendSingleThreadNotification] Empty notification state. Skipping.");
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -408,6 +408,11 @@ public class MessageNotifier {
|
|||
{
|
||||
Log.i(TAG, "sendMultiThreadNotification() signal: " + signal);
|
||||
|
||||
if (notificationState.getNotifications().isEmpty()) {
|
||||
Log.i(TAG, "[sendMultiThreadNotification] Empty notification state. Skipping.");
|
||||
return;
|
||||
}
|
||||
|
||||
MultipleRecipientNotificationBuilder builder = new MultipleRecipientNotificationBuilder(context, TextSecurePreferences.getNotificationPrivacy(context));
|
||||
List<NotificationItem> notifications = notificationState.getNotifications();
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue