Skip to content

Commit

Permalink
Bug fix: reset syntax highlighter across grep sections (#1613)
Browse files Browse the repository at this point in the history
  • Loading branch information
dandavison committed Jan 20, 2024
1 parent 9f66dc3 commit e208f4e
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/handlers/grep.rs
Expand Up @@ -116,6 +116,9 @@ impl<'a> StateMachine<'a> {
grep_line.path.to_string(),
grep_line.line_number,
);
if new_section {
self.painter.set_highlighter()
}
if new_path {
if let Some(lang) = handlers::diff_header::get_extension(&grep_line.path)
.or(self.config.default_language.as_deref())
Expand Down

0 comments on commit e208f4e

Please sign in to comment.