diff --git a/file/file_test.go b/file/file_test.go index d2cd44e7..84b623ee 100644 --- a/file/file_test.go +++ b/file/file_test.go @@ -65,7 +65,7 @@ func TestFileInsertAtWithoutCommit(t *testing.T) { } check(t, "TestFileInsertAt after TestFileInsertAtWithoutCommit", f, - &stateSummary{true, true, false, true, s1}) + &stateSummary{true, true, false, false, s1}) } const s1 = "hi 海老麺" diff --git a/file/observable_editable_buffer.go b/file/observable_editable_buffer.go index 8959530d..4acc91c6 100644 --- a/file/observable_editable_buffer.go +++ b/file/observable_editable_buffer.go @@ -249,7 +249,7 @@ func (e *ObservableEditableBuffer) ReadC(q int) rune { // as clean and is this File writable to a backing. They are combined in // this method. func (e *ObservableEditableBuffer) SaveableAndDirty() bool { - sad := (e.f.HasUncommitedChanges() || e.Dirty()) && !e.IsDirOrScratch() + sad := e.Dirty() && !e.IsDirOrScratch() return e.details.Name != "" && sad }