Skip to content

Commit

Permalink
fix: check if vim.g.sweetie is nil when extending config, fixes #9
Browse files Browse the repository at this point in the history
  • Loading branch information
NTBBloodbath committed Sep 2, 2023
1 parent baa2543 commit 2e42442
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lua/sweetie/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ local highlights = require("sweetie.highlights")
if not type(vim.g.sweetie) == "table" and not vim.tbl_isempty(vim.g.sweetie) then
vim.g.sweetie = default_config
else
vim.g.sweetie = vim.tbl_deep_extend("keep", vim.g.sweetie, default_config)
vim.g.sweetie = vim.tbl_deep_extend("keep", vim.g.sweetie or {}, default_config)
end

sweetie.set = function()
Expand Down

0 comments on commit 2e42442

Please sign in to comment.