Update leo/commands/node.rs

This commit is contained in:
Collin Chin 2022-08-23 19:13:36 +02:00 committed by GitHub
parent 378aed5f54
commit d4a78a5633
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -60,7 +60,7 @@ impl Command for Node {
} else { } else {
// Open the Leo build/ directory // Open the Leo build/ directory
let path = context.dir()?; let path = context.dir()?;
let build_directory = BuildDirectory::open(&path).map_err(|_| CliError::needs_leo_build); let build_directory = BuildDirectory::open(&path).map_err(|_| CliError::needs_leo_build)?;
// Change the cwd to the Leo build/ directory to deploy aleo files. // Change the cwd to the Leo build/ directory to deploy aleo files.
std::env::set_current_dir(&build_directory) std::env::set_current_dir(&build_directory)