From 28f0ee42eec811afcee42ba3cd9381c8390470f9 Mon Sep 17 00:00:00 2001 From: Evangelos Ribeiro Tzaras Date: Wed, 18 Jan 2023 11:16:48 +0100 Subject: [PATCH] ui-call-data: Assert best_match is set self->best_match is never NULL: The test suite used to wrap calls_contacts_provder_new() to always return NULL which in turn caused the best match to be NULL. This was done to avoid warnings raised by libfolks about missing the primary store (eds). This is no longer necessary as the environment now tells folks which backend to use. --- src/calls-ui-call-data.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/src/calls-ui-call-data.c b/src/calls-ui-call-data.c index 5a30da4..602ab2b 100644 --- a/src/calls-ui-call-data.c +++ b/src/calls-ui-call-data.c @@ -358,16 +358,10 @@ set_call_data (CallsUiCallData *self, manager = calls_manager_get_default (); contacts_provider = calls_manager_get_contacts_provider (manager); - /* the contacts provider should only be NULL when running the test suite */ - if (!contacts_provider) - return; - self->best_match = calls_contacts_provider_lookup_id (contacts_provider, calls_call_get_id (call)); - - if (!self->best_match) - return; + g_assert (self->best_match); g_signal_connect_object (self->best_match, "notify::name",