diff options
author | Matthias Beyer <mail@beyermatthias.de> | 2019-01-05 01:09:12 +0100 |
---|---|---|
committer | Matthias Beyer <mail@beyermatthias.de> | 2019-02-15 20:53:29 +0100 |
commit | ebf3f309a6d7f9623afc4ebae1f50346c82d345d (patch) | |
tree | 7c53d5545da01becee7bd9b0071eebabc29f1436 /lib | |
parent | 187b9489854c40adcd28c7f11eb8679d85a3e097 (diff) |
Adapt to new libimagstore::iter::Entries API
Use Entries::into_storeid_iter() for transforming iterator into right
type.
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/domain/libimaghabit/src/iter.rs | 4 | ||||
-rw-r--r-- | lib/domain/libimaghabit/src/store.rs | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/lib/domain/libimaghabit/src/iter.rs b/lib/domain/libimaghabit/src/iter.rs index 8a1e5a75..8cdb7c70 100644 --- a/lib/domain/libimaghabit/src/iter.rs +++ b/lib/domain/libimaghabit/src/iter.rs @@ -52,7 +52,7 @@ impl From<StoreIdIterator> for HabitTemplateStoreIdIterator { impl<'a> From<StoreIdIteratorWithStore<'a>> for HabitTemplateStoreIdIterator { fn from(sii: StoreIdIteratorWithStore<'a>) -> Self { - HabitTemplateStoreIdIterator(sii.without_store()) + HabitTemplateStoreIdIterator(sii.into_storeid_iter()) } } @@ -88,7 +88,7 @@ impl From<StoreIdIterator> for HabitInstanceStoreIdIterator { impl<'a> From<StoreIdIteratorWithStore<'a>> for HabitInstanceStoreIdIterator { fn from(sii: StoreIdIteratorWithStore<'a>) -> Self { - HabitInstanceStoreIdIterator(sii.without_store()) + HabitInstanceStoreIdIterator(sii.into_storeid_iter()) } } diff --git a/lib/domain/libimaghabit/src/store.rs b/lib/domain/libimaghabit/src/store.rs index 197a1b64..5fbcf0cd 100644 --- a/lib/domain/libimaghabit/src/store.rs +++ b/lib/domain/libimaghabit/src/store.rs @@ -49,11 +49,11 @@ pub trait HabitStore { impl HabitStore for Store { /// Get an iterator over all habits fn all_habit_templates(&self) -> Result<HabitTemplateStoreIdIterator> { - Ok(HabitTemplateStoreIdIterator::from(self.entries()?.without_store())) + Ok(HabitTemplateStoreIdIterator::from(self.entries()?.into_storeid_iter())) } fn all_habit_instances(&self) -> Result<HabitInstanceStoreIdIterator> { - Ok(HabitInstanceStoreIdIterator::from(self.entries()?.without_store())) + Ok(HabitInstanceStoreIdIterator::from(self.entries()?.into_storeid_iter())) } } |