fix theme toggle replace_word func args #294

v2.5
siduck 2 years ago
parent 619368a05e
commit 6ffabeac88

@ -159,7 +159,7 @@ M.toggle_theme = function()
config.ui.theme = (themes[1] == config.ui.theme and themes[2]) or themes[1] config.ui.theme = (themes[1] == config.ui.theme and themes[2]) or themes[1]
local old_theme = dofile(vim.fn.stdpath "config" .. "/lua/chadrc.lua").ui.theme local old_theme = dofile(vim.fn.stdpath "config" .. "/lua/chadrc.lua").ui.theme
require("nvchad.utils").replace_word(old_theme, config.ui.theme) require("nvchad.utils").replace_word('theme = "' .. old_theme, 'theme = "' .. config.ui.theme)
M.load_all_highlights() M.load_all_highlights()
end end

Loading…
Cancel
Save