Make sure empty arrays are properly transformed