Change signature: Link::exists(&Store)
This change is necessary because we need the store now to check whether a StoreId exists. Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
This commit is contained in:
parent
429ef9bc4c
commit
14a2485a8a
1 changed files with 3 additions and 3 deletions
|
@ -45,10 +45,10 @@ pub enum Link {
|
||||||
|
|
||||||
impl Link {
|
impl Link {
|
||||||
|
|
||||||
pub fn exists(&self) -> Result<bool> {
|
pub fn exists(&self, store: &Store) -> Result<bool> {
|
||||||
match *self {
|
match *self {
|
||||||
Link::Id { ref link } => link.exists(),
|
Link::Id { ref link } => store.exists(link.clone()),
|
||||||
Link::Annotated { ref link, .. } => link.exists(),
|
Link::Annotated { ref link, .. } => store.exists(link.clone()),
|
||||||
}
|
}
|
||||||
.map_err(From::from)
|
.map_err(From::from)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue