From f69f43c3f53be4ba0b682ddbe6550b6fa803b714 Mon Sep 17 00:00:00 2001 From: Guldoman Date: Wed, 18 Oct 2023 06:45:31 +0200 Subject: [PATCH] Mark unsaved named files as dirty (#1598) --- data/core/doc/init.lua | 1 + 1 file changed, 1 insertion(+) diff --git a/data/core/doc/init.lua b/data/core/doc/init.lua index 086e9f3e..deeb3816 100644 --- a/data/core/doc/init.lua +++ b/data/core/doc/init.lua @@ -123,6 +123,7 @@ end function Doc:is_dirty() if self.new_file then + if self.filename then return true end return #self.lines > 1 or #self.lines[1] > 1 else return self.clean_change_id ~= self:get_change_id()