Skip to content

Conversation

@patch0
Copy link
Contributor

@patch0 patch0 commented Mar 13, 2025

I noticed that if I went into a search/replace dialog Ox would freeze if I tried to find all instances of an empty string.

This PR checks to see if the string given in both the search prompt, the replace prompt, and next_match/prev_match is empty. If so, return from the current function early.

This is my first time writing Rust 😅 and I've not written any tests..!

I noticed that if I went into a search/replace dialog Ox would freeze if
I tried to find all instances of an empty string.  This PR checks to see
if the string given in both the search prompt, the replace prompt, and
next_match/prev_match is empty.  If so, return from the current function
early.
@curlpipe
Copy link
Owner

Thank you for the contribution! Glad to see the search / replace is more robust now.

@curlpipe curlpipe merged commit cfb43ac into curlpipe:master Mar 13, 2025
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants