fix: harden git status updates (#2533)
* fix for nil status error messages * simplify logic --------- Co-authored-by: Alexander Courtis <alex@courtis.org>
This commit is contained in:
parent
52a1c99bf0
commit
633811c53d
@ -14,13 +14,15 @@ local function get_dir_git_status(parent_ignored, status, absolute_path)
|
||||
return { file = "!!" }
|
||||
end
|
||||
|
||||
return {
|
||||
file = status.files and status.files[absolute_path],
|
||||
dir = status.dirs and {
|
||||
direct = status.dirs.direct[absolute_path],
|
||||
indirect = status.dirs.indirect[absolute_path],
|
||||
},
|
||||
}
|
||||
if status then
|
||||
return {
|
||||
file = status.files and status.files[absolute_path],
|
||||
dir = status.dirs and {
|
||||
direct = status.dirs.direct[absolute_path],
|
||||
indirect = status.dirs.indirect[absolute_path],
|
||||
},
|
||||
}
|
||||
end
|
||||
end
|
||||
|
||||
local function get_git_status(parent_ignored, status, absolute_path)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user