chore: handle null parameters on `ignore_branch`

main
olimorris 2024-07-02 19:32:12 +01:00
parent 0a9eebf5cc
commit a9138468f9
1 changed files with 2 additions and 2 deletions

View File

@ -80,12 +80,12 @@ local function ignore_dir(dir)
end end
---Is the current branch ignored for auto-saving and loading? ---Is the current branch ignored for auto-saving and loading?
---@param dir string Branch to be used for the session ---@param branch? string Branch to be used for the session
---@return boolean ---@return boolean
local function ignore_branch(branch) local function ignore_branch(branch)
local ignored_branches = config.options.ignored_branches local ignored_branches = config.options.ignored_branches
if ignored_branches == nil then if not branch or ignored_branches == nil then
return false return false
end end