Update crates/nu-command/src/filters/where_.rs

Co-authored-by: Bahex <Bahex@users.noreply.github.com>
This commit is contained in:
132ikl 2025-04-01 23:45:42 -04:00 committed by GitHub
parent cdbcf83b57
commit 1da3beb1ca
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -43,7 +43,10 @@ While where supports closure literals, they can not be read from a variable. To
])
.required(
"condition",
SyntaxShape::OneOf(vec![SyntaxShape::RowCondition, SyntaxShape::Closure(None)]),
SyntaxShape::OneOf(vec![
SyntaxShape::RowCondition,
SyntaxShape::Closure(Some(vec![SyntaxShape::Any])),
]),
"Filter row condition or closure.",
)
.allow_variants_without_examples(true)