fix: prevent double running of git command
Should improve loading times significantlymain
parent
86ce6f14ae
commit
bcdada28d2
|
|
@ -89,10 +89,6 @@ end
|
|||
function M.setup(opts)
|
||||
config.setup(opts)
|
||||
|
||||
if M.session_exists() then
|
||||
vim.g.persisted_exists = true
|
||||
end
|
||||
|
||||
if
|
||||
config.options.autosave
|
||||
and (allow_dir() and not ignore_dir() and vim.g.persisting == nil)
|
||||
|
|
|
|||
|
|
@ -86,6 +86,7 @@ function M.load_session(session, silent)
|
|||
return echoerr("Error loading the session! ", result)
|
||||
end
|
||||
|
||||
vim.g.persisted_exists = true
|
||||
vim.g.persisted_loaded_session = session
|
||||
vim.api.nvim_exec_autocmds("User", { pattern = "PersistedLoadPost", data = session })
|
||||
end
|
||||
|
|
|
|||
Loading…
Reference in New Issue