[gnome-contacts] window: Fix an unreachable catch clause



commit e9ed693346373bcd021300b78c3f106d644dc3d7
Author: Niels De Graef <nielsdegraef gmail com>
Date:   Fri Jun 5 11:24:48 2020 +0200

    window: Fix an unreachable catch clause

 src/contacts-window.vala | 12 +++++++-----
 1 file changed, 7 insertions(+), 5 deletions(-)
---
diff --git a/src/contacts-window.vala b/src/contacts-window.vala
index e409478..ff980a6 100644
--- a/src/contacts-window.vala
+++ b/src/contacts-window.vala
@@ -527,11 +527,13 @@ public class Contacts.Window : Gtk.ApplicationWindow {
           foreach (var i in individuals)
             foreach (var p in i.personas) {
               // TODO: make sure it is acctally removed
-              try {
-                p.store.remove_persona.begin (p);
-              } catch (Error e) {
-                debug ("Coudln't remove persona");
-              }
+              p.store.remove_persona.begin (p, (obj, res) => {
+                try {
+                  p.store.remove_persona.end (res);
+                } catch (Error e) {
+                  debug ("Coudln't remove persona: %s", e.message);
+                }
+              });
             }
       });
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]