Disable printing "local package ... not found" in release mode

This commit is contained in:
Felix Schütt
2022-11-03 09:52:30 +01:00
parent 16ebfd4ef5
commit 70078e5630
2 changed files with 25 additions and 14 deletions

View File

@@ -237,7 +237,11 @@ fn wasmer_main_inner() -> Result<(), anyhow::Error> {
// Check if the file is a package name
if let WasmerCLIOptions::Run(r) = &options {
return crate::commands::try_run_package_or_file(&args, r);
#[cfg(not(feature = "debug"))]
let debug = false;
#[cfg(feature = "debug")]
let debug = r.options.debug;
return crate::commands::try_run_package_or_file(&args, r, debug);
}
options.execute()