mirror of
https://github.com/pesde-pkg/pesde.git
synced 2025-04-10 13:50:56 +01:00
feat(engines): do not silence manifest read errors
Now reading the manifest will only be silenced if the error's cause is the manifest not being found.
This commit is contained in:
parent
684f711d93
commit
6ae7e5078c
1 changed files with 7 additions and 5 deletions
12
src/main.rs
12
src/main.rs
|
@ -286,11 +286,13 @@ async fn run() -> anyhow::Result<()> {
|
|||
break 'engines;
|
||||
};
|
||||
|
||||
let req = project
|
||||
.deser_manifest()
|
||||
.await
|
||||
.ok()
|
||||
.and_then(|mut manifest| manifest.engines.remove(&engine));
|
||||
let req = match project.deser_manifest().await {
|
||||
Ok(mut manifest) => manifest.engines.remove(&engine),
|
||||
Err(pesde::errors::ManifestReadError::Io(e)) if e.kind() == io::ErrorKind::NotFound => {
|
||||
None
|
||||
}
|
||||
Err(e) => return Err(e.into()),
|
||||
};
|
||||
|
||||
if engine == EngineKind::Pesde {
|
||||
match &req {
|
||||
|
|
Loading…
Add table
Reference in a new issue