Fixed for a case where an empty array would not be created