mirror of
https://gitlab.gnome.org/GNOME/calls.git
synced 2025-01-05 19:15:32 +00:00
contacts-row: Use g_autoptr
folks 0.14 (shipped in Debian Bullseye) has cleanup functions defined.
This commit is contained in:
parent
9b49b0bc4f
commit
c0cfaeaffe
1 changed files with 1 additions and 3 deletions
|
@ -74,8 +74,7 @@ phone_numbers_changed_cb (CallsContactsRow *self)
|
|||
phone_iter = gee_iterable_iterator (GEE_ITERABLE (phone_numbers));
|
||||
|
||||
while (gee_iterator_next (phone_iter)) {
|
||||
// FIXME: We can't use g_autoptr because it's not implemented in the folks version in debian
|
||||
FolksAbstractFieldDetails *detail = gee_iterator_get (phone_iter);
|
||||
g_autoptr (FolksAbstractFieldDetails) detail = gee_iterator_get (phone_iter);
|
||||
|
||||
if (FOLKS_IS_PHONE_FIELD_DETAILS (detail)) {
|
||||
FolksPhoneFieldDetails *phone = FOLKS_PHONE_FIELD_DETAILS (detail);
|
||||
|
@ -84,7 +83,6 @@ phone_numbers_changed_cb (CallsContactsRow *self)
|
|||
if (number)
|
||||
insert_phonenumber (self, number);
|
||||
}
|
||||
g_object_unref (detail);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue