Skip to content

Commit

Permalink
Fix the last path not showing up in breadcrumps
Browse files Browse the repository at this point in the history
  • Loading branch information
grego committed Jul 22, 2024
1 parent 42f0e71 commit 1cb447e
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/types.rs
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,11 @@ impl<'a> Content for Ancestors<'a> {
.render(encoder)?;
previous = i + sep.len();
}
if !s.contains(is_separator) {
if previous != 0 {
section
.with(&Segment(&s[previous..], &s))
.render(encoder)?;
} else {
section.with(&Segment(s, s)).render(encoder)?;
}
Ok(())
Expand Down

0 comments on commit 1cb447e

Please sign in to comment.