Skip to content

Commit 17338fa

Browse files
committed
make update works more friendly
1 parent cb1eefd commit 17338fa

1 file changed

Lines changed: 6 additions & 3 deletions

File tree

crates/nu-command/src/filters/update.rs

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@ use nu_engine::{eval_block, CallExt};
22
use nu_protocol::ast::{Call, CellPath, PathMember};
33
use nu_protocol::engine::{Closure, Command, EngineState, Stack};
44
use nu_protocol::{
5-
Category, Example, FromValue, IntoInterruptiblePipelineData, IntoPipelineData, PipelineData,
6-
ShellError, Signature, Span, SyntaxShape, Type, Value,
5+
Category, Example, FromValue, IntoInterruptiblePipelineData, PipelineData, ShellError,
6+
Signature, Span, SyntaxShape, Type, Value,
77
};
88

99
#[derive(Clone)]
@@ -122,7 +122,10 @@ fn update(
122122
&engine_state,
123123
&mut stack,
124124
&block,
125-
input.clone().into_pipeline_data(),
125+
input
126+
.clone()
127+
.follow_cell_path(&cell_path.members, false)
128+
.into_pipeline_data(None),
126129
redirect_stdout,
127130
redirect_stderr,
128131
);

0 commit comments

Comments
 (0)