fix wrong hunk highlighting after arrow-down at end of diff (closes #249)

This commit is contained in:
Stephan Dilly 2020-08-28 18:53:01 +02:00
parent aa1bf4fded
commit 40e9194b5d

View file

@ -215,8 +215,9 @@ impl DiffComponent {
}
};
self.selection =
Selection::Single(cmp::min(max, new_start));
let new_start = cmp::min(max, new_start);
self.selection = Selection::Single(new_start);
self.selected_hunk =
Self::find_selected_hunk(diff, new_start)?;