From b3cc41ceb2bc6a0a1e4a4226be697bab94bb0275 Mon Sep 17 00:00:00 2001 From: Andrea Zagli Date: Sun, 25 Jun 2017 13:03:46 +0200 Subject: [PATCH] In FormElementArray setted value in any case. --- src/formelementarray.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/formelementarray.c b/src/formelementarray.c index bb976a7..6c9b11f 100644 --- a/src/formelementarray.c +++ b/src/formelementarray.c @@ -411,12 +411,15 @@ zak_form_element_array_set_value (ZakFormElementArray *element, GValue *value) } /* assign value to the right FormElement */ - if (field_name != NULL - && field_value != NULL) + if (field_name != NULL) { form_element = zak_form_element_array_get_element_by_id (ZAK_FORM_ELEMENT (element), field_name); if (form_element != NULL) { + if (field_value == NULL) + { + field_value = zak_utils_gvalue_new_string (""); + } zak_form_element_set_value (ZAK_FORM_ELEMENT (form_element), field_value); } } -- 2.49.0