changeset 3502:96e514706d74

Fix bug bug #57423: Traceback when creating a local record with an empty field
author Luis Falcon <falcon@gnuhealth.org>
date Mon, 16 Dec 2019 11:13:40 +0000
parents 6f9accf1d2d8
children 95ed752f58ab
files plugins/frl/__init__.py
diffstat 1 files changed, 3 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/plugins/frl/__init__.py
+++ b/plugins/frl/__init__.py
@@ -185,7 +185,9 @@
             #string of the form field:fed_resource:fed_field
             field, fed_resource, fed_field = val.split(':')
 
-            local_vals[field] = fed_data[fed_field]
+            #Make sure that the element has a value 
+            if (fed_data[fed_field]):
+                local_vals[field] = fed_data[fed_field]
         return local_vals
 
     # Get the values from the selection on the FRL list view