ZIm/crates/search/src
Finn Evers e6267c42f7
Ensure pane: swap item right does not panic (#36765)
This fixes a panic I randomly ran into whilst mistyping in the command
palette: I accidentally ran `pane: swap item right`in a state where no
items were opened in my active pane. We were checking for `index + 1 ==
self.items.len()` there when it really should be `>=`, as otherwise in
the case of no items this panics.

This PR fixes the bug, adds a test for both the panic as well as the
actions themselves (they were untested previously). Lastly (and mostly),
this also cleans up a bit around existing actions to update them with
how we generally handle actions now.

Release Notes:

- Fixed a panic that could occur with the `pane: swap item right`
action.
2025-08-22 23:28:55 +02:00
..
buffer_search Fix clippy::redundant_clone lint violations (#36558) 2025-08-20 12:20:13 +02:00
buffer_search.rs Fix clippy::redundant_clone lint violations (#36558) 2025-08-20 12:20:13 +02:00
project_search.rs Ensure pane: swap item right does not panic (#36765) 2025-08-22 23:28:55 +02:00
search.rs lints: A bunch of extra style lint fixes (#36568) 2025-08-20 12:05:58 +02:00
search_bar.rs Fix clippy::needless_borrow lint violations (#36444) 2025-08-18 21:54:35 +00:00
search_status_button.rs search: Simplify search options handling (#36233) 2025-08-15 10:34:54 +00:00