[calls] best-match: Assert CALLS_IS_BEST_MATCH in private functions



commit 690ac121e9d8755ff2089d2ed40d82de266ca76a
Author: Evangelos Ribeiro Tzaras <devrtz fortysixandtwo eu>
Date:   Thu Feb 17 11:06:17 2022 +0100

    best-match: Assert CALLS_IS_BEST_MATCH in private functions

 src/calls-best-match.c | 4 ++++
 1 file changed, 4 insertions(+)
---
diff --git a/src/calls-best-match.c b/src/calls-best-match.c
index 2b44953b..7c8a2d9a 100644
--- a/src/calls-best-match.c
+++ b/src/calls-best-match.c
@@ -74,6 +74,8 @@ search_view_prepare_cb (FolksSearchView *view,
 static void
 notify_name (CallsBestMatch *self)
 {
+  g_assert (CALLS_IS_BEST_MATCH (self));
+
   g_object_notify_by_pspec (G_OBJECT (self), props[PROP_NAME]);
 }
 
@@ -81,6 +83,8 @@ notify_name (CallsBestMatch *self)
 static void
 notify_avatar (CallsBestMatch *self)
 {
+  g_assert (CALLS_IS_BEST_MATCH (self));
+
   g_object_notify_by_pspec (G_OBJECT (self), props[PROP_AVATAR]);
 }
 


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