Skip to content

Commit

Permalink
refactor: use repeat_n() instead of repeat().take() (#897)
Browse files Browse the repository at this point in the history
Signed-off-by: Nico Wagner <[email protected]>
  • Loading branch information
nwagner84 authored Feb 5, 2025
1 parent c0a7ae3 commit 43bce4b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/query.rs
Original file line number Diff line number Diff line change
Expand Up @@ -194,10 +194,10 @@ impl Fragment {
.fold(Outcome::default(), |acc, e| acc + e);

if outcome.is_empty() {
outcome = Outcome(vec![std::iter::repeat(
outcome = Outcome(vec![std::iter::repeat_n(
BString::from(""),
path.codes.len(),
)
.take(path.codes.len())
.collect()]);
}

Expand Down

0 comments on commit 43bce4b

Please sign in to comment.