1
0
Fork 0
mirror of https://gitlab.gnome.org/GNOME/calls.git synced 2024-09-29 15:25:24 +00:00

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.
This commit is contained in:
Evangelos Ribeiro Tzaras 2023-01-18 11:16:48 +01:00
parent 60ece1a656
commit 28f0ee42ee

View file

@ -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",