Skip to content

Commit

Permalink
fix for annotations_no_substores() and similar functions
Browse files Browse the repository at this point in the history
  • Loading branch information
proycon committed Sep 22, 2024
1 parent ca5c538 commit d41ab4b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "stam"
version = "0.16.0"
version = "0.16.1"
edition = "2021"
authors = ["Maarten van Gompel <[email protected]>"]
description = "STAM is a powerful library for dealing with stand-off annotations on text. This is the Rust library."
Expand Down
6 changes: 3 additions & 3 deletions src/api/annotationstore.rs
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ impl AnnotationStore {
ResultIter::new_sorted(
self.iter()
.map(|item: &TextResource| item.as_resultitem(self, self))
.filter(|res| self.resource_substore_map.get(res.handle()).is_some()),
.filter(|res| self.resource_substore_map.get(res.handle()).is_none()),
)
}

Expand All @@ -151,7 +151,7 @@ impl AnnotationStore {
ResultIter::new_sorted(
self.iter()
.map(|item: &AnnotationDataSet| item.as_resultitem(self, self))
.filter(|ds| self.dataset_substore_map.get(ds.handle()).is_some()),
.filter(|ds| self.dataset_substore_map.get(ds.handle()).is_none()),
)
}

Expand Down Expand Up @@ -179,7 +179,7 @@ impl AnnotationStore {
ResultIter::new_sorted(
self.iter()
.map(|a: &'a Annotation| a.as_resultitem(self, self))
.filter(|a| self.annotation_substore_map.get(a.handle()).is_some()),
.filter(|a| self.annotation_substore_map.get(a.handle()).is_none()),
)
}

Expand Down

0 comments on commit d41ab4b

Please sign in to comment.