Skip to content

Commit

Permalink
minor refactoring
Browse files Browse the repository at this point in the history
  • Loading branch information
frol committed Jul 5, 2024
1 parent 26521a3 commit be125ee
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/js_command_match/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,8 @@ pub enum JsCmd {
impl JsCmd {
pub fn rust_command_generation(&self) -> Result<(Vec<String>, String), String> {
let network = std::env::var("NEAR_NETWORK")
.unwrap_or_else(|_| std::env::var("NEAR_ENV").unwrap_or_else(|_| "testnet".to_owned()));
.or_else(|_| std::env::var("NEAR_ENV"))
.unwrap_or_else(|_| "testnet".to_owned());
let message = "The command you tried to run is deprecated in the new NEAR CLI, but we tried our best to match the old command with the new syntax, try it instead:".to_string();
let validator_extension_message = "The command you tried to run has been moved into its own CLI extension called near-validator.\nPlease, follow the installation instructions here: https://github.com/near-cli-rs/near-validator-cli-rs/blob/master/README.md".to_string();

Expand Down

0 comments on commit be125ee

Please sign in to comment.