Trip empty strings from dom to clean-up JSON structure