@@ -66,7 +66,7 @@ impl Editor {
6666 }
6767 }
6868
69− fn _open(&mut self, id: DocumentId, action: Action) -> Result<DocumentId, Error> {
69+ pub fn switch(&mut self, id: DocumentId, action: Action) -> Result<DocumentId, Error> {
7070 use crate::tree::Layout;
7171 use helix_core::Selection;
7272 match action {
@@ -115,7 +115,7 @@ impl Editor {
115115 let doc = Document::new(Rope::from("\n"));
116116 let id = self.documents.insert(doc);
117117 self.documents[id].id = id;
118− self._open(id, action)
118+ self.switch(id, action)
119119 }
120120
121121 pub fn open(&mut self, path: PathBuf, action: Action) -> Result<DocumentId, Error> {
@@ -159,7 +159,7 @@ impl Editor {
159159 id
160160 };
161161
162− self._open(id, action)
162+ self.switch(id, action)
163163 }
164164
165165 pub fn close(&mut self, id: ViewId) {