@@ -681,7 +681,7 @@ impl Editor {
682 // Remove the scratch buffer from any jumplists
682 // Remove the scratch buffer from any jumplists
683 for (view, _) in self.tree.views_mut() {
683 for (view, _) in self.tree.views_mut() {
684− view.jumps.remove(&id)
684+ view.remove_document(&id);
687 let jump = (view.doc, doc.selection(view.id).clone());
687 let jump = (view.doc, doc.selection(view.id).clone());
@@ -814,8 +814,7 @@ impl Editor {
815 .views_mut()
815 .views_mut()
816 .filter_map(|(view, _focus)| {
816 .filter_map(|(view, _focus)| {
817− // remove the document from jump list of all views
818− view.jumps.remove(&doc_id);
817+ view.remove_document(&doc_id);
820 if view.doc == doc_id {
819 if view.doc == doc_id {
821 // something was previously open in the view, switch to previous doc
820 // something was previously open in the view, switch to previous doc