dont error on empty saves
This commit is contained in:
parent
e6c6dd994d
commit
1caf2aa0f6
1 changed files with 1 additions and 1 deletions
|
@ -451,7 +451,7 @@ pub const Editor = struct {
|
|||
|
||||
fn save(self: *Self) !void {
|
||||
const b = if (self.buffer) |p| p else return error.Stop;
|
||||
if (!b.is_dirty()) return tp.exit("no changes to save");
|
||||
if (!b.is_dirty()) return self.logger.print("no changes to save", .{});
|
||||
if (self.file_path) |file_path| {
|
||||
if (self.buffer) |b_mut| try b_mut.store_to_file_and_clean(file_path);
|
||||
} else return error.SaveNoFileName;
|
||||
|
|
Loading…
Add table
Reference in a new issue