mirror of
https://github.com/moparisthebest/k-9
synced 2025-01-08 04:08:15 -05:00
Remove double synchronization
This commit is contained in:
parent
23c49d834d
commit
f8ea923522
@ -1810,18 +1810,16 @@ public class MessagingController implements Runnable {
|
||||
synchronized (data) {
|
||||
MessageReference ref = localMessage.makeMessageReference();
|
||||
if (data.removeMatchingMessage(context, ref)) {
|
||||
synchronized (data) {
|
||||
// if we remove a single message from the notification,
|
||||
// maybe there is a stacked notification active for that one message
|
||||
Integer childNotification = data.getStackedChildNotification(ref);
|
||||
if (childNotification != null) {
|
||||
NotificationManager notificationManager =
|
||||
(NotificationManager)context.getSystemService(Context.NOTIFICATION_SERVICE);
|
||||
notificationManager.cancel(childNotification);
|
||||
}
|
||||
// update the (summary-) notification
|
||||
notifyAccountWithDataLocked(context, account, null, data);
|
||||
// if we remove a single message from the notification,
|
||||
// maybe there is a stacked notification active for that one message
|
||||
Integer childNotification = data.getStackedChildNotification(ref);
|
||||
if (childNotification != null) {
|
||||
NotificationManager notificationManager =
|
||||
(NotificationManager)context.getSystemService(Context.NOTIFICATION_SERVICE);
|
||||
notificationManager.cancel(childNotification);
|
||||
}
|
||||
// update the (summary-) notification
|
||||
notifyAccountWithDataLocked(context, account, null, data);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user