Skip to content

Commit

Permalink
Merge branch 'main' of https://github.com/griccardos/rusl
Browse files Browse the repository at this point in the history
  • Loading branch information
griccardos committed Nov 14, 2023
2 parents daa7c24 + eb8d73f commit 8a60d0b
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions druid/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -328,9 +328,11 @@ impl AppDelegate<AppState> for Delegate {
data.interim_count = 0;

data.re_name = RegexBuilder::new(&data.text_name).case_insensitive(!data.name_case_sensitive).build();
data.re_content = RegexBuilder::new(&data.text_contents)
.case_insensitive(!data.content_case_sensitive)
.build();
let mut pattern = data.text_contents.to_string();
if data.content_nonregex {
pattern = regex::escape(&pattern);
}
data.re_content = RegexBuilder::new(&pattern).case_insensitive(!data.content_case_sensitive).build();

data.message = rich("Searching...", Color::YELLOW);
data.error_message = String::new();
Expand Down

0 comments on commit 8a60d0b

Please sign in to comment.