refactor: group_by is now stable under chunk_by

This commit is contained in:
Matthieu Bessat 2024-04-19 14:18:20 +02:00
parent d665bb8eaa
commit 1d88702bf1
2 changed files with 2 additions and 4 deletions

View file

@ -1,5 +1,3 @@
#![feature(slice_group_by)]
mod utils;
mod paheko;
mod helloasso;

View file

@ -401,9 +401,9 @@ impl AuthentifiedClient {
expiry_date: NaiveDate
}
let intermidiate: Vec<Row> = serde_json::from_value(val.results)?;
// regroup the row with the same id
// group the rows with the same id
Ok(intermidiate
.group_by(|a,b| a.id == b.id)
.chunk_by(|a,b| a.id == b.id)
.map(|rows| {
let base = rows.first().unwrap();