Convert empty strings to null

Fix subforms and prevent wrong validation errors in the forms