Compact error array to remove any null values.