Fix saving issues
@@ -125,8 +125,6 @@ public struct EditorView: View {
editorVC?.document?.editor = nil
- editorVC?.save { (_) in
-
func open() {
let document = PyDocument(fileURL: url)
document.open { (_) in
@@ -137,6 +135,7 @@ public struct EditorView: View {
editorVC?.parent?.parent?.title = editorVC?.parent?.title
editorVC?.parent?.parent?.parent?.title = editorVC?.parent?.title // I'm not kidding
editorVC?.document = document
+ document.editor = editorVC
editorVC?.viewWillAppear(false)
self.isOpeningStore.isOpening = false
}
@@ -162,7 +161,6 @@ public struct EditorView: View {
open()
}
}
- }
view = AnyView(editorStore.editor!)
}
