Remving duplicate count in metadata serde