Replace GlobError with link to ::glob::PatternError

This commit is contained in:
Matthias Beyer 2017-09-09 21:46:25 +02:00
parent 6aa695974c
commit 2ce2ba54da
2 changed files with 2 additions and 7 deletions

View file

@ -29,6 +29,7 @@ error_chain! {
foreign_links {
Io(::std::io::Error);
TomlDeserError(::toml::de::Error);
GlobPatternError(::glob::PatternError);
}
errors {
@ -158,11 +159,6 @@ error_chain! {
display("Header type is wrong")
}
GlobError {
description("glob() error")
display("glob() error")
}
EncodingError {
description("Encoding error")
display("Encoding error")

View file

@ -507,10 +507,9 @@ impl Store {
.and_then(|path| {
let path = [ path, "/**/*" ].join("");
debug!("glob()ing with '{}'", path);
glob(&path[..]).chain_err(|| SEK::GlobError)
glob(&path[..]).map_err(From::from)
})
.map(|paths| GlobStoreIdIterator::new(paths, self.path().clone()).into())
.chain_err(|| SEK::GlobError)
.chain_err(|| SEK::RetrieveForModuleCallError)
}