forked from extern/nushell
Remove EvaluationContext::from_args (#3604)
This commit is contained in:
@@ -33,7 +33,7 @@ impl WholeStreamCommand for SubCommand {
|
||||
|
||||
pub fn clear(args: CommandArgs) -> Result<OutputStream, ShellError> {
|
||||
let name = args.call_info.name_tag.clone();
|
||||
let ctx = EvaluationContext::from_args(&args);
|
||||
let ctx = &args.context;
|
||||
|
||||
let result = if let Some(global_cfg) = &mut args.configs().lock().global_config {
|
||||
global_cfg.vars.clear();
|
||||
|
@@ -37,7 +37,7 @@ impl WholeStreamCommand for SubCommand {
|
||||
|
||||
pub fn get(args: CommandArgs) -> Result<OutputStream, ShellError> {
|
||||
let name = args.call_info.name_tag.clone();
|
||||
let ctx = EvaluationContext::from_args(&args);
|
||||
let ctx = &args.context;
|
||||
|
||||
let column_path = args.req(0)?;
|
||||
|
||||
|
@@ -38,7 +38,7 @@ impl WholeStreamCommand for SubCommand {
|
||||
|
||||
pub fn remove(args: CommandArgs) -> Result<OutputStream, ShellError> {
|
||||
let name = args.call_info.name_tag.clone();
|
||||
let ctx = EvaluationContext::from_args(&args);
|
||||
let ctx = &args.context;
|
||||
let remove: Tagged<String> = args.req(0)?;
|
||||
|
||||
let key = remove.to_string();
|
||||
|
@@ -52,7 +52,7 @@ impl WholeStreamCommand for SubCommand {
|
||||
|
||||
pub fn set(args: CommandArgs) -> Result<OutputStream, ShellError> {
|
||||
let name = args.call_info.name_tag.clone();
|
||||
let ctx = EvaluationContext::from_args(&args);
|
||||
let ctx = &args.context;
|
||||
|
||||
let column_path = args.req(0)?;
|
||||
let mut value: Value = args.req(1)?;
|
||||
|
@@ -38,7 +38,7 @@ impl WholeStreamCommand for SubCommand {
|
||||
|
||||
pub fn set_into(args: CommandArgs) -> Result<OutputStream, ShellError> {
|
||||
let name = args.call_info.name_tag.clone();
|
||||
let ctx = EvaluationContext::from_args(&args);
|
||||
let ctx = &args.context;
|
||||
|
||||
let set_into: Tagged<String> = args.req(0)?;
|
||||
|
||||
|
Reference in New Issue
Block a user