diff options
author | Christian Chiarulli <[email protected]> | 2022-11-04 17:04:05 -0400 |
---|---|---|
committer | Christian Chiarulli <[email protected]> | 2022-11-04 17:32:46 -0400 |
commit | 08d3c056ffe989b97b11afee9ad1db108d3ccfb5 (patch) | |
tree | f5d2f26e602f232fcc115f4c38e29722e8b92148 /lua/lvim/core/autocmds.lua | |
parent | 57c159fe3c4aec49aeb5a4df78275e7092fc21fa (diff) |
chore: format on save off by default
chore: check if table
Diffstat (limited to 'lua/lvim/core/autocmds.lua')
-rw-r--r-- | lua/lvim/core/autocmds.lua | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lua/lvim/core/autocmds.lua b/lua/lvim/core/autocmds.lua index 21c7c1f0..61e3e676 100644 --- a/lua/lvim/core/autocmds.lua +++ b/lua/lvim/core/autocmds.lua @@ -158,7 +158,9 @@ function M.disable_format_on_save() end function M.configure_format_on_save() - if lvim.format_on_save then + if type(lvim.format_on_save) == "table" and lvim.format_on_save.enabled then + M.enable_format_on_save() + elseif lvim.format_on_save == true then M.enable_format_on_save() else M.disable_format_on_save() |