From 4a134144d124b7e2bb2812255ef00e44671730a9 Mon Sep 17 00:00:00 2001 From: Matthias Beyer Date: Sat, 28 May 2016 17:10:18 +0200 Subject: [PATCH] Add debugging in lib-iter --- libimagdiary/src/iter.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/libimagdiary/src/iter.rs b/libimagdiary/src/iter.rs index ce7aec78..1b2b16e5 100644 --- a/libimagdiary/src/iter.rs +++ b/libimagdiary/src/iter.rs @@ -82,15 +82,18 @@ impl<'a> Iterator for DiaryEntryIterator<'a> { debug!("Seems to be in diary: {:?}", next); let id = DiaryId::from_storeid(&next); if id.is_none() { + debug!("Couldn't parse {:?} into DiaryId", next); continue; } let id = id.unwrap(); + debug!("Success parsing id = {:?}", id); let y = match self.year { None => true, Some(y) => y == id.year() }; let m = match self.month { None => true, Some(m) => m == id.month() }; let d = match self.day { None => true, Some(d) => d == id.day() }; if y && m && d { + debug!("Return = {:?}", id); return Some(self .store .retrieve(next)