Skip to content

Commit dd2a458

Browse files
authored
fix: Getting started documentation now uses where instead of filter (deprecated) (#1961)
1 parent 5fd8b7c commit dd2a458

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

book/types_of_data.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -247,12 +247,12 @@ let cp = $.2
247247

248248
Simple example:
249249

250-
This closure returns a boolean result of the comparison and then uses it in a `filter` command to return all values greater than 5.
250+
This closure returns a boolean result of the comparison and then uses it in a `where` command to return all values greater than 5.
251251

252252
```nu
253253
let compare_closure = {|a| $a > 5 }
254254
let original_list = [ 40 -4 0 8 12 16 -16 ]
255-
$original_list | filter $compare_closure
255+
$original_list | where $compare_closure
256256
# => ╭───┬────╮
257257
# => │ 0 │ 40 │
258258
# => │ 1 │ 8 │

0 commit comments

Comments
 (0)