[geary: 12/13] Common case: don't add an insert operation if inserted_ids is empty
- From: Michael Gratton <mjog src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [geary: 12/13] Common case: don't add an insert operation if inserted_ids is empty
- Date: Sat, 2 Feb 2019 02:48:56 +0000 (UTC)
commit d694e849987ddd5ded8f92bca0c751d1ca3c2140
Author: James Magahern <james magahern com>
Date: Fri Jan 25 01:57:31 2019 -0800
Common case: don't add an insert operation if inserted_ids is empty
src/engine/app/app-conversation-monitor.vala | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
---
diff --git a/src/engine/app/app-conversation-monitor.vala b/src/engine/app/app-conversation-monitor.vala
index 510ccfa0..d9dd78af 100644
--- a/src/engine/app/app-conversation-monitor.vala
+++ b/src/engine/app/app-conversation-monitor.vala
@@ -893,7 +893,9 @@ public class Geary.App.ConversationMonitor : BaseObject {
}
// Notify about inserted messages
- this.queue.add(new InsertOperation(this, inserted_ids));
+ if (inserted_ids.size > 0) {
+ this.queue.add(new InsertOperation(this, inserted_ids));
+ }
// Notify self about removed conversations
// NOTE: We are only notifying the conversation monitor about the removed conversations instead of
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]