From 6ecf7551a2415e46e2aee52f16b3738c5362bf1a Mon Sep 17 00:00:00 2001 From: Mylloon Date: Mon, 15 Aug 2022 20:12:22 +0200 Subject: [PATCH] fix typo --- src/info.rs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/info.rs b/src/info.rs index f873848..de3c992 100644 --- a/src/info.rs +++ b/src/info.rs @@ -47,10 +47,12 @@ pub async fn info() -> HashMap, DateTime)>> { // -1 car la première semaine est déjà compté let end_date = start_date + Duration::weeks(rep - 1); - let mut vec = data.get(&i).unwrap().to_owned(); + let it = i + 1; + + let mut vec = data.get(&it).unwrap().to_owned(); vec.push((start_date, end_date)); - data.insert(i + 1, vec); + data.insert(it, vec); } _ => (), }